gpt4 book ai didi

Codeigniter Bootstrap 分页

转载 作者:行者123 更新时间:2023-12-03 18:14:57 25 4
gpt4 key购买 nike

我正在使用 CodeIgniter 和 Twitter Bootstrap 制作一个网络应用程序。我在网上找到了一个带有 $config 设置列表的资源,可以正确设置分页链接的样式。有没有办法将它存储在库中并将其加载到 Controller 中,这样我就不必每次都输入它?

最佳答案

您可以将其保存为 application/config 中的 pagination.php:

$config['per_page'] = 2;
$config['uri_segment'] = 3;
$config['num_links'] = 9;
$config['page_query_string'] = TRUE;

$config['query_string_segment'] = 'page';

$config['full_tag_open'] = '<div class="pagination"><ul>';
$config['full_tag_close'] = '</ul></div><!--pagination-->';

$config['first_link'] = '&laquo; First';
$config['first_tag_open'] = '<li class="prev page">';
$config['first_tag_close'] = '</li>';

$config['last_link'] = 'Last &raquo;';
$config['last_tag_open'] = '<li class="next page">';
$config['last_tag_close'] = '</li>';

$config['next_link'] = 'Next &rarr;';
$config['next_tag_open'] = '<li class="next page">';
$config['next_tag_close'] = '</li>';

$config['prev_link'] = '&larr; Previous';
$config['prev_tag_open'] = '<li class="prev page">';
$config['prev_tag_close'] = '</li>';

$config['cur_tag_open'] = '<li class="active"><a href="">';
$config['cur_tag_close'] = '</a></li>';

$config['num_tag_open'] = '<li class="page">';
$config['num_tag_close'] = '</li>';

$config['anchor_class'] = 'follow_link';

关于Codeigniter Bootstrap 分页,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/12164114/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com