Fix bug #3382126: Linked tags does not work for tags with spaces
This commit is contained in:
parent
889ca453ec
commit
dd29ad13eb
3 changed files with 5 additions and 5 deletions
|
@ -14,7 +14,7 @@ require_once('sidebar.linkedtags.inc.php');
|
||||||
/* Manage input */
|
/* Manage input */
|
||||||
$user = isset($user)?$user:'';
|
$user = isset($user)?$user:'';
|
||||||
$userid = isset($userid)?$userid:0;
|
$userid = isset($userid)?$userid:0;
|
||||||
$currenttag = isset($currenttag)?$currenttag:'';
|
$currenttag = isset($currenttag) ? str_replace('+', ',', $currenttag) : '';
|
||||||
//$summarizeLinkedTags = isset($summarizeLinkedTags)?$summarizeLinkedTags:false;
|
//$summarizeLinkedTags = isset($summarizeLinkedTags)?$summarizeLinkedTags:false;
|
||||||
|
|
||||||
$logged_on_userid = $userservice->getCurrentUserId();
|
$logged_on_userid = $userservice->getCurrentUserId();
|
||||||
|
|
|
@ -8,6 +8,7 @@ ChangeLog for SemantiScuttle
|
||||||
- Fix bug #3385724: Rename tag ends with XML Parsing Error
|
- Fix bug #3385724: Rename tag ends with XML Parsing Error
|
||||||
- Fix bug #3386178: "system:unfiled" secret tag does not work
|
- Fix bug #3386178: "system:unfiled" secret tag does not work
|
||||||
- Fix bug #3384416: Update documentation to explain HTTP/HTTPS root problem
|
- Fix bug #3384416: Update documentation to explain HTTP/HTTPS root problem
|
||||||
|
- Fix bug #3382126: Linked tags does not work for tags with spaces
|
||||||
- Fix delicious API help page link
|
- Fix delicious API help page link
|
||||||
|
|
||||||
Run ``scripts/fix-unfiled-tags.php`` to fix old bookmarks that miss the
|
Run ``scripts/fix-unfiled-tags.php`` to fix old bookmarks that miss the
|
||||||
|
|
|
@ -1,13 +1,12 @@
|
||||||
<?php
|
<?php
|
||||||
/**
|
/**
|
||||||
* Returns a list of tags linked to the given one,
|
* Returns a list of tags linked to the given one(s),
|
||||||
* suitable for jsTree consumption.
|
* suitable for jsTree consumption.
|
||||||
*
|
*
|
||||||
* Accepted GET parameters:
|
* Accepted GET parameters:
|
||||||
*
|
*
|
||||||
* @param string $tag Tag for which the children tags shall be returned
|
* @param string $tag Tag for which the children tags shall be returned
|
||||||
* Multiple tags (separated with space or "+") are
|
* Multiple tags (separated with comma) are supported.
|
||||||
* supported.
|
|
||||||
* If no tag is given, all top-level tags are loaded.
|
* If no tag is given, all top-level tags are loaded.
|
||||||
* @param integer $uId User ID to fetch the tags for
|
* @param integer $uId User ID to fetch the tags for
|
||||||
* @param boolean $parent Load parent tags
|
* @param boolean $parent Load parent tags
|
||||||
|
@ -32,7 +31,7 @@ $tag = isset($_GET['tag']) ? $_GET['tag'] : null;
|
||||||
$uId = isset($_GET['uId']) ? (int)$_GET['uId'] : 0;
|
$uId = isset($_GET['uId']) ? (int)$_GET['uId'] : 0;
|
||||||
$loadParentTags = isset($_GET['parent']) ? (bool)$_GET['parent'] : false;
|
$loadParentTags = isset($_GET['parent']) ? (bool)$_GET['parent'] : false;
|
||||||
|
|
||||||
$tags = explode(' ', trim($tag));
|
$tags = explode(',', trim($tag));
|
||||||
if (count($tags) == 1 && $tags[0] == '') {
|
if (count($tags) == 1 && $tags[0] == '') {
|
||||||
//no tags
|
//no tags
|
||||||
$tags = array();
|
$tags = array();
|
||||||
|
|
Loading…
Reference in a new issue