[geeklog-cvs] Geeklog-1.x/public_html/admin/plugins/links category.php, 1.11, 1.12

Dirk Haun dhaun at qs1489.pair.com
Mon Dec 31 07:27:11 EST 2007


Update of /cvsroot/geeklog/Geeklog-1.x/public_html/admin/plugins/links
In directory qs1489.pair.com:/tmp/cvs-serv36929/public_html/admin/plugins/links

Modified Files:
	category.php 
Log Message:
Added "All" topic for categories


Index: category.php
===================================================================
RCS file: /cvsroot/geeklog/Geeklog-1.x/public_html/admin/plugins/links/category.php,v
retrieving revision 1.11
retrieving revision 1.12
diff -C2 -d -r1.11 -r1.12
*** category.php	30 Dec 2007 16:27:51 -0000	1.11
--- category.php	31 Dec 2007 12:27:09 -0000	1.12
***************
*** 231,236 ****
          $T->set_var('category_value', $A['category']);
          $T->set_var('description_value', $A['description']);
-         $T->set_var('topic_list',
-                     COM_topicList('tid,topic', $A['tid'], 1, true));
      } else {
          $A['cid'] = COM_makeSid();
--- 231,234 ----
***************
*** 240,245 ****
          $T->set_var('category_value', '');
          $T->set_var('description_value', '');
-         $T->set_var('topic_list', COM_topicList('tid,topic', '', 1, true));
      }
  
      // user access info
--- 238,255 ----
          $T->set_var('category_value', '');
          $T->set_var('description_value', '');
      }
+ 
+     if (!isset($A['tid'])) {
+         $A['tid'] = 'all';
+     }
+     $topics = COM_topicList('tid,topic', $A['tid'], 1, true);
+     $T->set_var('topic_list', $topics);
+     $alltopics = '<option value="all"';
+     if ($A['tid'] == 'all') {
+         $alltopics .= ' selected="selected"';
+     }
+     $alltopics .= '>' . $LANG_LINKS_ADMIN[35] . '</option>' . LB;
+     $T->set_var('topic_selection', '<select name="tid">' . $alltopics
+                                    . $topics . '</select>');
  
      // user access info




More information about the geeklog-cvs mailing list