Changeset 796:43a9cace0f39
- Timestamp:
- 02/08/12 23:10:39 (13 years ago)
- Branch:
- 2.4
- Location:
- admin
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
admin/comments.php
r795 r796 45 45 /* Get comments 46 46 -------------------------------------------------------- */ 47 $author = isset($_GET['author']) ? html::escapeHTML($_GET['author']): '';48 $status = isset($_GET['status']) ? html::escapeHTML($_GET['status']): '';49 $type = !empty($_GET['type']) ? html::escapeHTML($_GET['type']): '';50 $sortby = !empty($_GET['sortby']) ? html::escapeHTML($_GET['sortby']): 'comment_dt';51 $order = !empty($_GET['order']) ? html::escapeHTML($_GET['order']): 'desc';52 $ip = !empty($_GET['ip']) ? html::escapeHTML($_GET['ip']): '';47 $author = isset($_GET['author']) ? $_GET['author'] : ''; 48 $status = isset($_GET['status']) ? $_GET['status'] : ''; 49 $type = !empty($_GET['type']) ? $_GET['type'] : ''; 50 $sortby = !empty($_GET['sortby']) ? $_GET['sortby'] : 'comment_dt'; 51 $order = !empty($_GET['order']) ? $_GET['order'] : 'desc'; 52 $ip = !empty($_GET['ip']) ? $_GET['ip'] : ''; 53 53 54 54 $with_spam = $author || $status || $type || $sortby != 'comment_dt' || $order != 'desc' || $ip; … … 73 73 $params['q_author'] = $author; 74 74 $show_filters = true; 75 } else { 76 $author=''; 75 77 } 76 78 … … 79 81 $params['comment_trackback'] = ($type == 'tb'); 80 82 $show_filters = true; 83 } else { 84 $type=''; 81 85 } 82 86 … … 87 91 } elseif (!$with_spam) { 88 92 $params['comment_status_not'] = -2; 93 $status=''; 94 } else { 95 $status=''; 89 96 } 90 97 … … 99 106 if ($order !== '' && in_array($order,$order_combo)) { 100 107 $params['order'] = $sortby.' '.$order; 108 } else { 109 $order = 'desc'; 101 110 } 102 111 … … 104 113 $show_filters = true; 105 114 } 115 } else { 116 $sortby = 'comment_dt'; 117 $order = 'desc'; 106 118 } 107 119 -
admin/posts.php
r795 r796 138 138 /* Get posts 139 139 -------------------------------------------------------- */ 140 $user_id = !empty($_GET['user_id']) ? html::escapeHTML($_GET['user_id']): '';141 $cat_id = !empty($_GET['cat_id']) ? html::escapeHTML($_GET['cat_id']): '';142 $status = isset($_GET['status']) ? html::escapeHTML($_GET['status']): '';143 $selected = isset($_GET['selected']) ? html::escapeHTML($_GET['selected']): '';144 $month = !empty($_GET['month']) ? html::escapeHTML($_GET['month']): '';145 $lang = !empty($_GET['lang']) ? html::escapeHTML($_GET['lang']): '';146 $sortby = !empty($_GET['sortby']) ? html::escapeHTML($_GET['sortby']): 'post_dt';147 $order = !empty($_GET['order']) ? html::escapeHTML($_GET['order']): 'desc';140 $user_id = !empty($_GET['user_id']) ? $_GET['user_id'] : ''; 141 $cat_id = !empty($_GET['cat_id']) ? $_GET['cat_id'] : ''; 142 $status = isset($_GET['status']) ? $_GET['status'] : ''; 143 $selected = isset($_GET['selected']) ? $_GET['selected'] : ''; 144 $month = !empty($_GET['month']) ? $_GET['month'] : ''; 145 $lang = !empty($_GET['lang']) ? $_GET['lang'] : ''; 146 $sortby = !empty($_GET['sortby']) ? $_GET['sortby'] : 'post_dt'; 147 $order = !empty($_GET['order']) ? $_GET['order'] : 'desc'; 148 148 149 149 $show_filters = false; … … 166 166 $params['user_id'] = $user_id; 167 167 $show_filters = true; 168 } else { 169 $user_id=''; 168 170 } 169 171 … … 172 174 $params['cat_id'] = $cat_id; 173 175 $show_filters = true; 176 } else { 177 $cat_id=''; 174 178 } 175 179 … … 178 182 $params['post_status'] = $status; 179 183 $show_filters = true; 184 } else { 185 $status=''; 180 186 } 181 187 … … 184 190 $params['post_selected'] = $selected; 185 191 $show_filters = true; 192 } else { 193 $selected=''; 186 194 } 187 195 … … 191 199 $params['post_year'] = substr($month,0,4); 192 200 $show_filters = true; 201 } else { 202 $month=''; 193 203 } 194 204 … … 197 207 $params['post_lang'] = $lang; 198 208 $show_filters = true; 209 } else { 210 $lang=''; 199 211 } 200 212 … … 203 215 if ($order !== '' && in_array($order,$order_combo)) { 204 216 $params['order'] = $sortby.' '.$order; 217 } else { 218 $order='desc'; 205 219 } 206 220 … … 208 222 $show_filters = true; 209 223 } 224 } else { 225 $sortby='post_dt'; 226 $order='desc'; 210 227 } 211 228
Note: See TracChangeset
for help on using the changeset viewer.