aboutsummaryrefslogtreecommitdiff
path: root/services
diff options
context:
space:
mode:
authormensonge <mensonge@b3834d28-1941-0410-a4f8-b48e95affb8f>2008-01-11 09:34:32 +0000
committermensonge <mensonge@b3834d28-1941-0410-a4f8-b48e95affb8f>2008-01-11 09:34:32 +0000
commit0bfd4e4d3f4fa3db0b2de50277b0cfbddcf6efdf (patch)
tree02a9e7a282f8e5c46596d728e76ec72170e38a9a /services
parentcfbf95ebe5417875e739eacf344304f478d855c0 (diff)
downloadsemanticscuttle-0bfd4e4d3f4fa3db0b2de50277b0cfbddcf6efdf.tar.gz
semanticscuttle-0bfd4e4d3f4fa3db0b2de50277b0cfbddcf6efdf.tar.bz2
Interface design: structured tags on frontpage and tag pages + permission control added to add and delete tag links
git-svn-id: https://semanticscuttle.svn.sourceforge.net/svnroot/semanticscuttle/trunk@10 b3834d28-1941-0410-a4f8-b48e95affb8f
Diffstat (limited to 'services')
-rw-r--r--services/tag2tagservice.php10
1 files changed, 7 insertions, 3 deletions
diff --git a/services/tag2tagservice.php b/services/tag2tagservice.php
index 0b53d64..d522039 100644
--- a/services/tag2tagservice.php
+++ b/services/tag2tagservice.php
@@ -88,14 +88,18 @@ class Tag2TagService {
return $output;
}
- function getOrphewTags($relationType, $uId) {
+ function getOrphewTags($relationType, $uId = 0) {
$query = "SELECT DISTINCT tag1 as tag FROM `". $this->getTableName() ."`";
$query.= " WHERE tag1 <> ALL";
$query.= " (SELECT DISTINCT tag2 FROM `". $this->getTableName() ."`";
$query.= " WHERE relationType = '".$relationType."'";
- $query.= " AND uId = '".$uId."'";
+ if($uId > 0) {
+ $query.= " AND uId = '".$uId."'";
+ }
$query.= ")";
- $query.= " AND uId = '".$uId."'";
+ if($uId > 0) {
+ $query.= " AND uId = '".$uId."'";
+ }
//die($query);