Changeset 1059 in ExiteCMS
- Timestamp:
- 11/05/07 21:03:15 (4 years ago)
- Location:
- trunk/modules/user_info_panel
- Files:
-
- 2 edited
-
templates/modules.user_info_panel.tpl (modified) (1 diff)
-
user_info_panel.php (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/modules/user_info_panel/templates/modules.user_info_panel.tpl
r978 r1059 39 39 <hr /> 40 40 <div style='text-align:center'> 41 <a href='{$smarty.const.MODULES}forum_threads_list_panel/new_posts.php' class='side'><b>{$new_post_msg|string_format:$locale.090}{if $new_post_msg == 1}{$locale.088}{else}{$locale.089}{/if}</b></a> 42 <hr /> 43 {buttonlink name=$locale.091 link=$smarty.const.MODULES|cat:"forum_threads_list_panel/new_posts.php?markasread="|cat:$user_id} 41 {if $new_posts_panel} 42 <a href='{$smarty.const.MODULES}forum_threads_list_panel/new_posts.php' class='side'><b>{$new_post_msg|string_format:$locale.090}{if $new_post_msg == 1}{$locale.088}{else}{$locale.089}{/if}</b></a> 43 <hr /> 44 {buttonlink name=$locale.091 link=$smarty.const.MODULES|cat:"forum_threads_list_panel/new_posts.php?markasread="|cat:$user_id} 45 {else} 46 <b>{$new_post_msg|string_format:$locale.090}{if $new_post_msg == 1}{$locale.088}{else}{$locale.089}{/if}</b> 47 {/if} 44 48 </div> 45 49 {/if} -
trunk/modules/user_info_panel/user_info_panel.php
r954 r1059 19 19 20 20 if (isset($userdata['user_id'])) { 21 $variables['new_pm_msg'] = dbcount("(pmindex_id)", "pm_index", "pmindex_user_id ='".$userdata['user_id']."' AND pmindex_to_id='".$userdata['user_id']."' AND pmindex_read_datestamp = '0'"); 22 $variables['new_post_msg'] = dbcount("(post_id)", "posts_unread", "user_id='".$userdata['user_id']."'"); 21 // store the user's ID and name 23 22 $variables['user_id'] = isset($userdata['user_id'])?$userdata['user_id']:0; 24 23 $variables['user_name'] = isset($userdata['user_name'])?$userdata['user_name']:""; 24 // if an administrator, check to which pages this admin has access to 25 25 if (iADMIN) { 26 26 $usr_rghts = " (admin_rights='".str_replace(".", "' OR admin_rights='", $userdata['user_rights'])."')"; … … 30 30 $variables['adminpage4'] = dbcount("(*)", "admin", $usr_rghts." AND admin_link!='reserved' AND admin_page='4'"); 31 31 } 32 $variables['new_pm_msg'] = dbcount("(pmindex_id)", "pm_index", "pmindex_user_id ='".$userdata['user_id']."' AND pmindex_to_id='".$userdata['user_id']."' AND pmindex_read_datestamp = '0'"); 33 $variables['new_post_msg'] = dbcount("(post_id)", "posts_unread", "user_id='".$userdata['user_id']."'"); 34 // check if the forum_threads_list_panel module is installed 35 $result = dbquery("SELECT * FROM ".$db_prefix."modules WHERE mod_folder = 'forum_threads_list_panel'"); 36 $variables['new_posts_panel'] = dbrows($result); 32 37 } 33 38 $variables['loginerror'] = isset($loginerror) ? $loginerror : "";
Note: See TracChangeset
for help on using the changeset viewer.
