From d6889066c0d285bf59e89b484800443304585b68 Mon Sep 17 00:00:00 2001 From: mensonge Date: Fri, 5 Dec 2008 07:25:04 +0000 Subject: Major Refactoring: finish transforming into object . Put and into header.inc.php. git-svn-id: https://semanticscuttle.svn.sourceforge.net/svnroot/semanticscuttle/trunk@199 b3834d28-1941-0410-a4f8-b48e95affb8f --- ajax/getlinkedtags.php | 1 - ajax/gettags.php | 11 ++--------- 2 files changed, 2 insertions(+), 10 deletions(-) (limited to 'ajax') diff --git a/ajax/getlinkedtags.php b/ajax/getlinkedtags.php index feb70ae..24d00fc 100644 --- a/ajax/getlinkedtags.php +++ b/ajax/getlinkedtags.php @@ -26,7 +26,6 @@ require_once('../header.inc.php'); /* Service creation: only useful services are created */ $b2tservice =& ServiceFactory::getServiceInstance('Bookmark2TagService'); $bookmarkservice =& ServiceFactory::getServiceInstance('TagService'); -$userservice =& ServiceFactory::getServiceInstance('UserService'); $tagstatservice =& ServiceFactory::getServiceInstance('TagStatService'); /* Managing all possible inputs */ diff --git a/ajax/gettags.php b/ajax/gettags.php index 167c63d..7b8b33a 100644 --- a/ajax/gettags.php +++ b/ajax/gettags.php @@ -23,23 +23,16 @@ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA require_once('../header.inc.php'); +/* Service creation: only useful services are created */ $b2tservice =& ServiceFactory::getServiceInstance('Bookmark2TagService'); $bookmarkservice =& ServiceFactory::getServiceInstance('TagService'); -$userservice =& ServiceFactory::getServiceInstance('UserService'); - -if ($userservice->isLoggedOn()) { - $loggedon = true; - $currentUser = $userservice->getCurrentUser(); - $currentUserID = $userservice->getCurrentUserId(); - $currentUsername = $currentUser[$userservice->getFieldName('username')]; -} ?> {identifier:"tag", items: [ getPopularTags($currentUserID, 1000, $currentUserID); + $listTags = $b2tservice->getPopularTags($userservice->getCurrentUserId(), 1000, $userservice->getCurrentUserId()); foreach($listTags as $t) { echo "{tag: \"".$t['tag']."\"},"; } -- cgit v1.2.3