Home  >  Article  >  CMS Tutorial  >  How to arrange DEDE sequentially from 0 to 1?

How to arrange DEDE sequentially from 0 to 1?

藏色散人
藏色散人Original
2019-12-25 10:19:322643browse

How to arrange DEDE sequentially from 0 to 1?

DEDE How to arrange the numbers from 0 to 1?

The debugger uses [field:global name=autoindex/] to call the specified channel and the CSS code needs to be added in front of the channel. The CSS code happens to be arranged by serial number, so I modified the code, here Share it with everyone. Friends who are interested can save it

Recommended study: 梦Weavercms

Today I debug the program for others and use [field:global name= autoindex/ ] Call the specified channel. The CSS code needs to be added in front of the channel. The CSS code is arranged according to the serial number.

Suddenly discovered that it starts from 0. So I modified the code!

If It starts from 0 like me, and you want it to start from 1, then use this code:

[field:global name=autoindex runphp="yes"]@me=@me+1;[/field:global]

On the contrary, if it starts from 1, and you want it to start from 0, Then use this code:

[field:global name=autoindex runphp="yes"]@me=@me-1;[/field:global]

Learn and use it, I hope everyone can adapt and study more DEDE codes and programs

The above is the detailed content of How to arrange DEDE sequentially from 0 to 1?. For more information, please follow other related articles on the PHP Chinese website!

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn