Index: trunk/phpwiki/fpw/special_recentchanges.php |
— | — | @@ -117,19 +117,19 @@ |
118 | 118 | o1.old_comment AS cur_comment, o1.old_user AS cur_user, |
119 | 119 | o1.old_user_text AS cur_user_text, o1.old_minor_edit, |
120 | 120 | COUNT(DISTINCT o2.old_id ) AS changes |
121 | | - FROM old AS o1 LEFT OUTER JOIN old AS o2 |
122 | | - ON o1.old_title = o2.old_title |
123 | | - AND o2.old_timestamp > SUBDATE(CURRENT_TIMESTAMP, INTERVAL 3 DAY) |
124 | | - AND o2.old_old_version <> 0 AND o2.old_minor_edit != 1 |
125 | | - $fromCondOld2 |
126 | | - WHERE o1.old_timestamp > SUBDATE(CURRENT_TIMESTAMP, INTERVAL 3 DAY) |
127 | | - AND o1.old_minor_edit != 1 |
128 | | - $fromCondOld1 |
| 121 | + FROM old AS o1, old AS o2 |
| 122 | + WHERE o1.old_title = o2.old_title |
| 123 | + AND o2.old_timestamp > SUBDATE(CURRENT_TIMESTAMP, INTERVAL $daysAgo DAY) |
| 124 | + AND o2.old_old_version <> 0 AND o2.old_minor_edit != 1 |
| 125 | + $fromCondOld2 |
| 126 | + AND o1.old_timestamp > SUBDATE(CURRENT_TIMESTAMP, INTERVAL $daysAgo DAY) |
| 127 | + AND o1.old_minor_edit != 1 |
| 128 | + $fromCondOld1 |
129 | 129 | GROUP BY o1.old_title, o1.old_timestamp |
130 | 130 | HAVING cur_timestamp = MAX(o2.old_timestamp) |
131 | 131 | ORDER BY o1.old_title |
132 | 132 | LIMIT $maxcnt"; |
133 | | - |
| 133 | + |
134 | 134 | # store result in $arr2 |
135 | 135 | $arr2 = array () ; |
136 | 136 | $result = mysql_query ( $sql2 , $connection ) ; |