Minor fix: correct menu boxes and tag normalization
git-svn-id: https://semanticscuttle.svn.sourceforge.net/svnroot/semanticscuttle/trunk@180 b3834d28-1941-0410-a4f8-b48e95affb8f
This commit is contained in:
parent
e0949aa0ad
commit
cf213449b1
4 changed files with 14 additions and 4 deletions
|
@ -80,6 +80,15 @@ class TagService {
|
||||||
function normalize($tags) {
|
function normalize($tags) {
|
||||||
//clean tags from strange characters
|
//clean tags from strange characters
|
||||||
$tags = str_replace(array('"', '\'', '/'), "_", $tags);
|
$tags = str_replace(array('"', '\'', '/'), "_", $tags);
|
||||||
|
|
||||||
|
//normalize
|
||||||
|
if(!is_array($tags)) {
|
||||||
|
$tags = strtolower(trim($tags));
|
||||||
|
} else {
|
||||||
|
for($i=0; $i<count($tags); $i++) {
|
||||||
|
$tags[$i] = strtolower(trim($tags[$i]));
|
||||||
|
}
|
||||||
|
}
|
||||||
return $tags;
|
return $tags;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -21,7 +21,7 @@ if(($logged_on_userid != null) && ($userid === $logged_on_userid)) {
|
||||||
$editingMode = false;
|
$editingMode = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
if(!isset($user)) {
|
if(!isset($user) || $user == '') {
|
||||||
$cat_url = createURL('tags', '%2$s');
|
$cat_url = createURL('tags', '%2$s');
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -14,11 +14,12 @@ if ($logged_on_userid === false) {
|
||||||
$logged_on_userid = NULL;
|
$logged_on_userid = NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
if(!isset($user)) {
|
if(!isset($user) || $user == '') {
|
||||||
$cat_url = createURL('tags', '%2$s');
|
$cat_url = createURL('tags', '%2$s');
|
||||||
}
|
}
|
||||||
|
|
||||||
$menu2Tags = $GLOBALS['menu2Tags'];
|
$menu2Tags = $GLOBALS['menu2Tags'];
|
||||||
|
|
||||||
if (sizeOf($menu2Tags) > 0) {
|
if (sizeOf($menu2Tags) > 0) {
|
||||||
?>
|
?>
|
||||||
|
|
||||||
|
|
|
@ -23,12 +23,12 @@ if(isset($rsschannels)) {
|
||||||
src="<?php echo ROOT ?>jsScuttle.php"></script>
|
src="<?php echo ROOT ?>jsScuttle.php"></script>
|
||||||
|
|
||||||
|
|
||||||
<!-- link rel="stylesheet" type="text/css"
|
<link rel="stylesheet" type="text/css"
|
||||||
href="http://ajax.googleapis.com/ajax/libs/dojo/1.2/dijit/themes/nihilo/nihilo.css">
|
href="http://ajax.googleapis.com/ajax/libs/dojo/1.2/dijit/themes/nihilo/nihilo.css">
|
||||||
|
|
||||||
<script type="text/javascript"
|
<script type="text/javascript"
|
||||||
src="http://ajax.googleapis.com/ajax/libs/dojo/1.2/dojo/dojo.xd.js"
|
src="http://ajax.googleapis.com/ajax/libs/dojo/1.2/dojo/dojo.xd.js"
|
||||||
djConfig="parseOnLoad:true, isDebug:false, usePlainJson:true"></script> -->
|
djConfig="parseOnLoad:true, isDebug:false, usePlainJson:true"></script>
|
||||||
|
|
||||||
<script type="text/javascript">
|
<script type="text/javascript">
|
||||||
dojo.require("dojo.parser");
|
dojo.require("dojo.parser");
|
||||||
|
|
Loading…
Add table
Reference in a new issue