Changeset 1322 in ExiteCMS
- Timestamp:
- 02/28/08 00:27:46 (4 years ago)
- Location:
- trunk
- Files:
-
- 2 edited
-
administration/modules.php (modified) (1 diff)
-
forum/index.php (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/administration/modules.php
r1281 r1322 480 480 $this_module['id'] = $data['mod_id']; 481 481 $this_module['version'] = $data['mod_version']; 482 if ($mod_version > $data['mod_version']) { 482 // convert the versions to a number 483 $new = explode(".", $mod_version); 484 while (count($new) < 4) { array_unshift($new, 0); } 485 $new = 1 * $new[3] + 100 * $new[2] + 10000 * $new[1] + 1000000 * $new[0]; 486 $cur = explode(".", $data['mod_version']); 487 while (count($cur) < 4) { array_unshift($cur, 0); } 488 $cur = 1 * $cur[3] + 100 * $cur[2] + 10000 * $cur[1] + 1000000 * $cur[0]; 489 // now compare the numeric version numbers 490 if ($new > $cur) { 483 491 if ($filter && $filter != 2) continue; 484 492 $this_module['status'] = 2; -
trunk/forum/index.php
r1311 r1322 81 81 if (iMEMBER) { 82 82 if ($userdata['user_posts_unread']) { 83 $result = dbquery("83 $result2 = dbquery(" 84 84 SELECT count(*) as unread 85 85 FROM ".$db_prefix."posts p 86 86 LEFT JOIN ".$db_prefix."threads_read tr ON p.thread_id = tr.thread_id 87 87 WHERE tr.user_id = '".$userdata['user_id']."' 88 AND tr.forum_id = '".$data['forum_id']."' 88 89 AND (p.post_datestamp > ".$settings['unread_threshold']." OR p.post_edittime > ".$settings['unread_threshold'].") 89 90 AND ((p.post_datestamp > tr.thread_last_read OR p.post_edittime > tr.thread_last_read) … … 91 92 ); 92 93 } else { 93 $result = dbquery("94 $result2 = dbquery(" 94 95 SELECT count(*) as unread 95 96 FROM ".$db_prefix."posts p 96 97 LEFT JOIN ".$db_prefix."threads_read tr ON p.thread_id = tr.thread_id 97 98 WHERE tr.user_id = '".$userdata['user_id']."' 99 AND tr.forum_id = '".$data['forum_id']."' 98 100 AND p.post_author != '".$userdata['user_id']."' 99 101 AND p.post_edituser != '".$userdata['user_id']."'
Note: See TracChangeset
for help on using the changeset viewer.
