Changeset 782:01efbf050a8a for admin/popup_posts.php
- Timestamp:
- 12/06/11 11:43:14 (14 years ago)
- Branch:
- formfilters
- Parents:
- 781:b509ac00bf4a (diff), 779:58c45f1b96e5 (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the (diff) links above to see all the changes relative to each parent. - Files:
-
- 2 edited
-
admin/popup_posts.php (modified) (3 diffs)
-
admin/popup_posts.php (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
admin/popup_posts.php
r557 r782 17 17 $q = !empty($_GET['q']) ? $_GET['q'] : null; 18 18 19 $page = !empty($_GET['page']) ? (integer) $_GET['page'] : 1; 20 $nb_per_page = 10; 19 $post_list = new adminPostMiniList($core); 21 20 22 21 $params = array(); 23 $params['limit'] = array((($page-1)*$nb_per_page),$nb_per_page);24 22 $params['no_content'] = true; 25 $params['order'] = 'post_dt DESC'; 23 24 # - Limit, sortby and order filter 25 $params = $post_list->applyFilters($params); 26 26 27 27 if ($q) { … … 43 43 $posts = $core->blog->getPosts($params); 44 44 $counter = $core->blog->getPosts($params,true); 45 $post_list = new adminPostMiniList($core,$posts,$counter->f(0));45 $post_list->setItems($posts,$counter->f(0)); 46 46 } catch (Exception $e) { 47 47 $core->error->add($e->getMessage()); … … 49 49 50 50 echo '<div id="form-entries">'; # I know it's not a form but we just need the ID 51 $post_list->display( $page,$nb_per_page);51 $post_list->display(); 52 52 echo '</div>'; 53 53 -
admin/popup_posts.php
r520 r782 4 4 # This file is part of Dotclear 2. 5 5 # 6 # Copyright (c) 2003-201 0Olivier Meunier & Association Dotclear6 # Copyright (c) 2003-2011 Olivier Meunier & Association Dotclear 7 7 # Licensed under the GPL version 2.0 license. 8 8 # See LICENSE file or … … 33 33 dcPage::jsLoad('js/jsToolBar/popup_posts.js')); 34 34 35 echo '<h2 >'.__('Add a link to an entry').'</h2>';35 echo '<h2 class="page-title">'.__('Add a link to an entry').'</h2>'; 36 36 37 37 echo '<form action="popup_posts.php" method="get">'. 38 38 '<p><label for="q" class="classic">'.__('Search entry:').' '.form::field('q',30,255,html::escapeHTML($q)).'</label> '. 39 ' <input type="submit" value="'.__(' ok').'" /></p>'.39 ' <input type="submit" value="'.__('Search').'" /></p>'. 40 40 '</form>'; 41 41
Note: See TracChangeset
for help on using the changeset viewer.
