


dede5.7 template dede31 paging text collection filtering rules detailed graphic tutorial continued four
At this point, the paging content matching is completed.
After article content matching and paging content matching are completed, there is only "filtering" in the end, including paging area filtering and article content filtering. According to my own feeling, the above two rules are easy to write. As long as you find the "uniqueness" code in all links, you can get it done. However, there are endless mysteries in the filtering rules that I can't explain... Haha, it feels like That's it. Especially for a novice like me, the word "regularity" is like a book from heaven. I searched for several regularity-related software and still found it impossible to start, so I had to follow the same pattern, imitate the cat and the tiger, and fumble around.
Okay, enough gossip. If you are tired, just listen to "Hotel California" and relax here: Hotel California_Eagles 94 Live.
Have you figured out how to write the filtering rules at a glance? Anyway, I couldn’t figure it out. I can’t help it. A novice is a novice. Ignore it, then write a rule according to the original example of paging filtering rules and try it to see the result:
Copy the code The code is as follows:
{dede:trim}
Collect it:

Paging is successful, but there are many waste codes and need to be changed!
Look at the redundant code features, it seems to be The filtering scope is not enough, and a lot of subsequent content needs to be filtered out. Well, move the filtering area further back, directly to the red part (in fact, when I changed the filtering rules, I changed it several times, so I’ll just do it here once, so as not to waste my friends’ time):

Write a complete paging filtering rule:
Copy the code The code is as follows:
{dede:trim}
Collect it again and see the results:

Okay, paging is successful, no redundant code. At this point, all the main code parts are completed.
The results are here:
With pagination: Materials for rectification and analysis of the style of party members and cadres
Without pagination: Work plan of the Ministry of Literature and Art
Write a completed site rule:
Copy the code The code is as follows:
{!-- Basic node information --}
{dede:item name='Tianshui_Work Plan_1 Page'
imgurl='/upimg' imgdir='../upimg' language='gb2312' typeid= '1' macthtype='string'}
{/dede:item}
{!-- Collection list acquisition rules --}
{dede:list source='var' sourcetype='list'
varstart='' varend= ''}
{dede:url value='http://www.tiansou.net/Html/Y_CYFW/R_Gzzj/F_Gzjh/index.html'}{/dede:url}
{dede:need}Gzjh/2007- {/dede:need}
{dede:cannot}Gzjh/2007-1{/dede:cannot}
{dede:linkarea}[var:area]{/dede:linkarea}
{/dede:list}
{! -- Web page content acquisition rules --}
{dede:art}
{dede:sppage sptype='full'}
{dede:note field='dede_archives.title' value='[var:content]' comment='article title'
isunit='' isdown=''}
{dede:match }
{dede:function}{/dede:function}
{/dede:note}
{dede:note field ='dede_archives.sortrank' value='[var:content]' comment='sort level'
isunit='' isdown=''}
{dede:match}{/dede:match}
{dede:function}@ me = time();{/dede:function}
{/dede:note}
{dede:note field='dede_archives.writer' value='[var:content]' comment='article author'
isunit=' ' isdown=''}
{dede:match}{/dede:match}
{dede:function}{/dede:function}
{/dede:note}
{dede:note field='dede_archives.litpic' value ='[var:content]' comment='thumbnail'
isunit='' isdown=''}
{dede:match}{/dede:match}
{dede:function}@me = @litpic;{/ dede:function}
{/dede:note}
{dede:note field='dede_archives.pubdate' value='[var:content]' comment='release time'
isunit='' isdown=''}
{ dede:match}{/dede:match}
{dede:function}if(@me!="") @me = GetMkTime(@me);
else @me = time();{/dede:function}
{/dede:note}
{dede:note field='dede_archives.senddate' value='[var:content]' comment='entry time'
isunit='' isdown=''}
{dede:match}{ /dede:match}
{dede:function}@me = time();{/dede:function}
{/dede:note}
{dede:note field='dede_addonarticle.body' value='[var:content | TD>
TR>{/dede:match}
{dede:trim}
{dede:trim}
{/dede:trim}
{dede:trim}]*)>{/dede:trim}
{dede:trim}< embed([^>]*)>([^>]*){/dede:trim}
{dede:trim}{/dede:trim}
{dede:trim}

Hot AI Tools

Undresser.AI Undress
AI-powered app for creating realistic nude photos

AI Clothes Remover
Online AI tool for removing clothes from photos.

Undress AI Tool
Undress images for free

Clothoff.io
AI clothes remover

AI Hentai Generator
Generate AI Hentai for free.

Hot Article

Hot Tools

Notepad++7.3.1
Easy-to-use and free code editor

SublimeText3 Chinese version
Chinese version, very easy to use

Zend Studio 13.0.1
Powerful PHP integrated development environment

Dreamweaver CS6
Visual web development tools

SublimeText3 Mac version
God-level code editing software (SublimeText3)

Hot Topics



Alipay PHP...

JWT is an open standard based on JSON, used to securely transmit information between parties, mainly for identity authentication and information exchange. 1. JWT consists of three parts: Header, Payload and Signature. 2. The working principle of JWT includes three steps: generating JWT, verifying JWT and parsing Payload. 3. When using JWT for authentication in PHP, JWT can be generated and verified, and user role and permission information can be included in advanced usage. 4. Common errors include signature verification failure, token expiration, and payload oversized. Debugging skills include using debugging tools and logging. 5. Performance optimization and best practices include using appropriate signature algorithms, setting validity periods reasonably,

The application of SOLID principle in PHP development includes: 1. Single responsibility principle (SRP): Each class is responsible for only one function. 2. Open and close principle (OCP): Changes are achieved through extension rather than modification. 3. Lisch's Substitution Principle (LSP): Subclasses can replace base classes without affecting program accuracy. 4. Interface isolation principle (ISP): Use fine-grained interfaces to avoid dependencies and unused methods. 5. Dependency inversion principle (DIP): High and low-level modules rely on abstraction and are implemented through dependency injection.

How to automatically set the permissions of unixsocket after the system restarts. Every time the system restarts, we need to execute the following command to modify the permissions of unixsocket: sudo...

Article discusses late static binding (LSB) in PHP, introduced in PHP 5.3, allowing runtime resolution of static method calls for more flexible inheritance.Main issue: LSB vs. traditional polymorphism; LSB's practical applications and potential perfo

Sending JSON data using PHP's cURL library In PHP development, it is often necessary to interact with external APIs. One of the common ways is to use cURL library to send POST�...

Article discusses essential security features in frameworks to protect against vulnerabilities, including input validation, authentication, and regular updates.

How to debug CLI mode in PHPStorm? When developing with PHPStorm, sometimes we need to debug PHP in command line interface (CLI) mode...
