Module

Archived
Forum
(read-only)

Sitemap Module

ExpressionEngine 2, ExpressionEngine 3, ExpressionEngine 4, ExpressionEngine 5, ExpressionEngine 6

Back to this add-on's main page
View Other Add-ons From Brian Litzinger

     

start/limit - confused!

Support (Resolved)

mel
mel

The most recent entry id on this site is 13359, so I want to start to show items in the sitemap that are recent (2012, not all the way back to 2009).

{exp:sitemap:get limit=“1000” start=“12000”}

The rendered sitemap is empty. I decreased start by 1000 each time (11,000, 10,000, 9,000 etc) until I get to 1000 and then items started to appear again, but they were from 2009.

Is there a way to simply set this to display in descending order so, the last 1000 posts (regardless of channel) are displayed?

Thanks.

PutYourLightsOn
# 1
PutYourLightsOn

hi mel,

the start parameter does not represent an entry_id but instead the offset, so setting it to 100 would skip the first 100 oldest entries. the reason for this parameter is that google has a limit on how many items can be submitted per sitemap so this makes it possible to generate several sitemaps. what you could do is try to figure out how many entries you need to skip before the 2012 entries come in and set that as the start value. so for example:

{exp:sitemap:get start="1000"

just increase the start value until you see only 2012 entries. hope this works for you.

ben

mel
# 2
mel

Thanks for the reply. I didn’t think it was an entry id, I assumed it was a offset from the beginning and I couldn’t understand why if I offset it by 12000 (when I have over 13000 entries) nothing showed up.