Skip Navigation

[Resolved] Renumber the bullet point number according to the page

This support ticket is created 3 years, 1 month ago. There's a good chance that you are reading advice that it now obsolete.

This is the technical support forum for Toolset - a suite of plugins for developing WordPress sites without writing PHP.

Everyone can read this forum, but only Toolset clients can post in it. Toolset support works 6 days per week, 19 hours per day.

Sun Mon Tue Wed Thu Fri Sat
- 9:00 – 13:00 9:00 – 13:00 9:00 – 13:00 9:00 – 13:00 9:00 – 13:00 -
- 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 -

Supporter timezone: Asia/Karachi (GMT+05:00)

This topic contains 3 replies, has 3 voices.

Last updated by Waqar 3 years, 1 month ago.

Assisted by: Waqar.

Author
Posts
#2272231
Screenshot 2022-01-21 at 4.51.54 PM.png

Dear Sir/Madam,

I have a View with pagination, there are 10 posts per page, how can I renumber the bullet point number according to the page, please refer to the screenshot, when I show the second page, the bullet point number should be started from 11 instead of 1. Please advise how I can get the page number and renumber it.

Best regards,

Kelvin.

#2272249

Nigel
Supporter

Languages: English (English ) Spanish (Español )

Timezone: Europe/London (GMT+00:00)

How do you generate the bullet point number?

#2272273

Dear Nigel,

Here is the code

	[wpv-items-found]
	<!-- wpv-loop-start -->
		<ol>
		<wpv-loop>
          <li><a href="/view-chapter/?ebook-id=[wpv-post-id item='$current_page']&&wpv_view_count=7334&wpv_paged=[wpv-loop-index accumulate="false"]">[wpv-post-title]</a></li>
		</wpv-loop>
        </ol>
[wpv-pager-nav-links output="bootstrap"]
	<!-- wpv-loop-end -->
	[/wpv-items-found]
#2273727

Thank you for sharing these details.

To achieve this, you can use the value from the "wpv-loop-index" shortcode, in the ol tag's "start" attribute:


...
<ol start="[wpv-loop-index accumulate='true' offset='1']">
<wpv-loop>
...
</wpv-loop>
</ol>
...

Related links:
https://toolset.com/documentation/programmer-reference/views/views-shortcodes/#wpv-loop-index
hidden link