aboutsummaryrefslogtreecommitdiffstats
path: root/mod
diff options
context:
space:
mode:
Diffstat (limited to 'mod')
-rw-r--r--mod/directory.php7
-rw-r--r--mod/dirsearch.php2
2 files changed, 7 insertions, 2 deletions
diff --git a/mod/directory.php b/mod/directory.php
index 4ab118b17..dca96694e 100644
--- a/mod/directory.php
+++ b/mod/directory.php
@@ -144,11 +144,14 @@ function directory_content(&$a) {
}
if($url) {
- // We might want to make the tagadelic count (&kw=) configurable or turn it off completely.
$numtags = get_config('system','directorytags');
- $kw = ((intval($numtags)) ? $numtags : 50);
+ $kw = ((intval($numtags) > 0) ? intval($numtags) : 50);
+
+ if(get_config('system','disable_directory_keywords'))
+ $kw = 0;
+
$query = $url . '?f=&kw=' . $kw . (($safe_mode != 1) ? '&safe=' . $safe_mode : '');
if($token)
diff --git a/mod/dirsearch.php b/mod/dirsearch.php
index 388e5f3ac..bc2fa108f 100644
--- a/mod/dirsearch.php
+++ b/mod/dirsearch.php
@@ -75,6 +75,8 @@ function dirsearch_content(&$a) {
$kw = ((x($_REQUEST,'kw')) ? intval($_REQUEST['kw']) : 0 );
$forums = ((array_key_exists('pubforums',$_REQUEST)) ? intval($_REQUEST['pubforums']) : 0);
+ if(get_config('system','disable_directory_keywords'))
+ $kw = 0;
// by default use a safe search