From 6fc0f8fc022e0ce9fc873e76efd3ae83f43cc9da Mon Sep 17 00:00:00 2001 From: Michael Vogel Date: Fri, 6 Apr 2012 14:56:53 +0200 Subject: [PATCH] Removed plugin "pages" because it was absolete. (Replaced by "page") --- pages.tgz | Bin 1390 -> 1375 bytes pages/README | 3 -- pages/pages.php | 93 ------------------------------------------------ 3 files changed, 96 deletions(-) delete mode 100755 pages/README delete mode 100755 pages/pages.php diff --git a/pages.tgz b/pages.tgz index 1a0aa4187669861309319e2b263aa6fa61bf5431..5fd23f7302f3a9d134af0a0a10e329531c0793c6 100644 GIT binary patch literal 1375 zcmV-l1)%yLiwFSR=YCHB1MOFBZ`(Ey&R6?a+=#4_1IM!R=ApIS1*wY;Xp+KB+Yf;e zGZJkPmPL=Gl4e8y`;MgSC{CJeAF^VY9vGIzdw9otm9?N#rh<)UMH|uC-#6DC{83yx zcD=wx7i%j#vbK8CI63NVe@alTZ?4zEH<9V z|9*I|Yx2JvhV9+(ppE%Q@!kfspXD@b_@C#$`x>)e54N`IumvY{&R)U?Qw-+z4O5Zi z3(ZCL5fi1eK|ji7^6a?`akUDYznROl2`@H{#6;Da4g!c07R`WN zF?j>mjLl#oB1oswm~H#Ph+@bz%r3flX{I$z+WjkH=0N1#42Jj8Fe+EGrzI@ z%fVi|z16XXjHNFL%RmbO0=1!$OlUNgXE98ej*_y`i4=2tzmQ_WQ-%sQkqGevO<2{05xJ@`LHGtNRSd8s-rB_5Y)2Hy_uaT( zW-EK6SEfaEE;GNp>A_BzGHrig8}Qgvq^*5t-dc`fX{b1k$R>Q62i+}FhuWhA_00*YDVA+=-NQ8*Klkw45WYS09CNOaWlXKk(kPzpX1Bzo41+vIS zDyCCBH*U-oldkqq{dT{gVBlP*gw)-~5?8%KUx$dcW@*U~;YS~YQ_<#hvG?gqH;R)Miq zSlMvh{A-GE|XQr;)F zSW8Dl5k|rV&3zk6dEzV`Z9pFrTX-mxdsx~B13F^#oqN*7uo~W^B60#rI4VdhUsA#J<&E_v=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iH#+`>qtK})|4B|mXCj#goaiOoC|D!p0S8v{CG%SP;5<>j#Qs~>p_ - * - */ - -function pages_install() { - register_hook('page_end', 'addon/pages/pages.php', 'pages_page_end'); -} - -function pages_uninstall() { - unregister_hook('page_end', 'addon/pages/pages.php', 'pages_page_end'); -} - -function pages_iscommunity($url, &$pagelist) { - // check every week for the status - should be enough - if ($pagelist[$url]["checked"]') != 0); - - $pagelist[$url] = array("community" => $iscommunity, "checked" => time()); - } else // Fetch from cache - $iscommunity = $pagelist[$url]["community"]; - return($iscommunity); -} - -function pages_getpages($uid) { - - // Fetch cached pagelist from configuration - $pagelist = get_pconfig($uid,'pages','pagelist'); - - if (sizeof($pagelist) == 0) - $pagelist = array(); - - $contacts = q("SELECT `id`, `url`, `Name` FROM `contact` - WHERE `network`= 'dfrn' AND `uid` = %d", - intval($uid)); - - $pages = array(); - - // Look if the profile is a community page - foreach($contacts as $contact) { - if (pages_iscommunity($contact["url"], $pagelist)) - $pages[] = array("url"=>$contact["url"], "Name"=>$contact["Name"], "id"=>$contact["id"]); - } - - // Write back cached pagelist - set_pconfig($uid,'pages','pagelist', $pagelist); - return($pages); -} - -function pages_page_end($a,&$b) { - // Only move on if if it's the "network" module and there is a logged on user - if (($a->module != "network") OR ($a->user['uid'] == 0)) - return; - - $pages = '
-
-

'.t("Community").'

-
"; - if (sizeof($contacts) > 0) { - $pos = strpos($a->page['aside'], '
0) { - $a->page['aside'] = substr($a->page['aside'], 0, $pos).$pages.substr($a->page['aside'], $pos); - } else - $a->page['aside'] = $pages.$a->page['aside']; - } -} -?>