Changeset 25629 for extensions/AdminTools/include/events.inc.php
- Timestamp:
- Nov 21, 2013, 9:13:41 PM (10 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
extensions/AdminTools/include/events.inc.php
r25619 r25629 11 11 } 12 12 13 global $template, $page ;13 global $template, $page, $user; 14 14 15 15 $url_root = get_root_url(); … … 20 20 'U_SELF' => $MultiView->get_clean_url(true), 21 21 'USER' => $MultiView->get_user(), 22 'CURRENT_USERNAME' => $user['id']==$conf['guest_id'] ? l10n('guest') : $user['username'], 22 23 ); 23 24 … … 37 38 )); 38 39 40 $query = 'SELECT element_id FROM ' . CADDIE_TABLE . ' 41 WHERE element_id = ' . $page['image_id'] .';'; 42 $tpl_vars['IS_IN_CADDIE'] = pwg_db_num_rows(pwg_query($query)) > 0; 43 39 44 if (isset($page['category'])) 40 45 { 46 $tpl_vars['CATEGORY_ID'] = $page['category']['id']; 47 41 48 $tpl_vars['U_SET_REPRESENTATIVE'] = add_url_params( 42 49 $url_self, 43 50 array('action'=>'set_as_representative') 44 51 ); 45 $tpl_vars['CATEGORY_ID'] = $page['category']['id']; 52 53 $query = 'SELECT id FROM ' . CATEGORIES_TABLE.' 54 WHERE id = ' . $page['category']['id'] .' 55 AND representative_picture_id = ' . $page['image_id'] .';'; 56 $tpl_vars['IS_REPRESENTATIVE'] = pwg_db_num_rows(pwg_query($query)) > 0; 46 57 } 47 58
Note: See TracChangeset
for help on using the changeset viewer.