Mason Kessinger - 20 August 2008 07:37 PM
Otherwise we’re still back at square one where we are unable to tell the difference in EE between single-entries and weblog pagination as I am unable to find conditional that can tell the difference between “www.domain.com/weblog/entry_title” and “www.domain.com/weblog/P33”
Mason, I haven’t used pagination much, but tonight I’m trying to do the exact same things as you: “getting conditional code that can detect whether or not {segment_3} is a pagination URL.”
I really want to use a single template for my pagination and the single entry, as it simply makes more sense from the layout of my sitemap/wireframe/mockup.
Here are the URLs as they work now:
http://www.site.com/items/ - a general page with featured entries, and a gigantic list of all items
http://www.site.com/items/P## - paginating through the huge list of the items
http://www.site.com/items/item/itemtitle/ - had to make a new template called ‘item’ to handle the single entry for this area
I absolutely can use a single template (as I’m doing elsewhere on the site) to handle the “landing page” for an area as well as the single-entry version of the page with a couple {if segment_3 != “”} and {if segment_3 == “”} conditionals. But when I introduce pagination, everything gets messed up. I would prefer my URLs for this area look like this:
http://www.site.com/items/ - same as above
http://www.site.com/items/P## - same as above
http://www.site.com/items/itemtitle/ - now using same template for pagination and single entry
Seems like a perfect opportunity to write a plugin to make a conditional based on whether the page is a pagination page or not. I’m with Mason on this - is a second template for a single entry the “approved” way to go here?