前面的教程中,我们已经介绍了的方法。站长朋友们在使用的过程中,通常还需要自定义不同分类页面每页显示条数。比如新闻分类页面我们希望每页显示10条新闻,而产品分类页面,我们希望每页显示9个产品。这篇教程里,我们就向大家介绍一下方法。
切换到主题目录,打开functions.PHP文件,加入以下代码:
Crayon-5c891ce0c3aef113607351" class="Crayon-Syntax Crayon-theme-classic Crayon-font-monaco Crayon-os-pc print-yes notranslate" data-settings=" minimize scroll-mouSEOver" style=" margin-top: 12px; margin-bottom: 12px; font-size: 12px !important; line-height: 15px !important;">
Crayon-toolbar" data-settings=" mouSEOver overlay hide delay" style="font-size: 12px !important;height: 18px !important; line-height: 18px !important;">Crayon-title">functions.PHP
Crayon-tools" style="font-size: 12px !important;height: 18px !important; line-height: 18px !important;">
Crayon-button Crayon-nums-button" title="Toggle Line Numbers">
Crayon-button-icon">
Crayon-button Crayon-plain-button" title="Toggle Plain Code">
Crayon-button-icon">
Crayon-button Crayon-wrap-button" title="Toggle Line Wrap">
Crayon-button-icon">
Crayon-button Crayon-expand-button" title="Expand Code">
Crayon-button-icon">
Crayon-button Crayon-copy-button" title="Copy">
Crayon-button-icon">
Crayon-button Crayon-popup-button" title="Open Code In New Window">
Crayon-language">PHPCrayon-button-icon">
Crayon-info" style="min-height: 16.8px !important; line-height: 16.8px !important;">
Crayon-plain-wrap">
Crayon-main" style="">Crayon-table">
Crayon-nums " data-settings="show"> Crayon-nums-content" style="font-size: 12px !important; line-height: 15px !important;"> Crayon-num" data-line="Crayon-5c891ce0c3aef113607351-1">1 Crayon-num" data-line="Crayon-5c891ce0c3aef113607351-3">3 Crayon-num" data-line="Crayon-5c891ce0c3aef113607351-5">5 Crayon-num" data-line="Crayon-5c891ce0c3aef113607351-7">7 Crayon-num" data-line="Crayon-5c891ce0c3aef113607351-9">9 | Crayon-code">