Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#1 2014-04-15 11:27:56

raminrahimi
Member
From: India
Registered: 2013-03-19
Posts: 276

how to add number with each title

i have created form (all-archive) there just shows the titles of each article.
now when i see all the titles, is it possible to add number with each title, like: 1, 2, 3, …
with CSS i can, but there is a pagination at the bottom, i’ve arround 200 articles.

Last edited by raminrahimi (2014-04-15 11:28:15)

Offline

#2 2014-04-15 12:06:29

uli
Moderator
From: Cologne
Registered: 2006-08-15
Posts: 4,304

Re: how to add number with each title

What about a CSS/TXP mixture? Inside your <head> you put a style tag with (around the lines of it):

H3:before { counter-reset: <txp:adi_calc name="reset" value="50" multiply='<txp:page_url type="pg" />' />
<txp:adi_calc name="reset" subtract="49" display="1" />; }

Where 50 is the number of articles on your page.
Please note: Use this just as a scaffold, have a look at the correct use of the adi_calc attributes.


In bad weather I never leave home without wet_plugout, smd_where_used and adi_form_links

Offline

Board footer

Powered by FluxBB