We use cookies to improve your experience. No personal information is gathered and we don't serve ads. Cookies Policy.

ExpressionEngine Logo ExpressionEngine
Features Pricing Support Find A Developer
Partners Upgrades
Blog Add-Ons Learn
Docs Forums University
Log In or Sign Up
Log In Sign Up
ExpressionEngine Logo
Features Pro new Support Find A Developer
Partners Upgrades
Blog Add-Ons Learn
Docs Forums University Blog
  • Home
  • Forums

Plugin: MD Detect Page Type. Pagination, categories, yearly archives and single entries all on one template.

Development and Programming

Joe Wolin's avatar
Joe Wolin
206 posts
15 years ago
Joe Wolin's avatar Joe Wolin

I’m currently using this plugin as I really want to keep my urls clean. So far it works great!

My only concern is the overhead that might come from the conditionals. In your example code it appears the conditionals are setup as advanced conditionals?

{exp:md_detect_page_type url_segment="{segment_2}"}
    {!-- if segment_2 is empty or it equals P## --}
    {if pagination_page || segment_2 == ""}

I’m wondering if this should be changed to the following to create a simple conditional on the inside to prevent futher parsing if segment_2 is not empty

{exp:md_detect_page_type url_segment="{segment_2}"}
    {!-- if segment_2 is empty or it equals P## --}
    {if pagination_page== ""}
       {if segment_2 == ""}    {!-- This sets up the simple conditional --}

Whats your thoughts on this… Would it improve page parsing?

       
Joe Wolin's avatar
Joe Wolin
206 posts
15 years ago
Joe Wolin's avatar Joe Wolin

Err… my example won’t work. Still thinking of ways to support a simple conditional on this. Let me know if you have any ideas.

       
Hendrik Dacquin's avatar
Hendrik Dacquin
3 posts
15 years ago
Hendrik Dacquin's avatar Hendrik Dacquin

I am really into this plugin as it makes cleaner URL’s possible. Is a 2.0 upgrade planned? 😊

Thanks + hugs

hendrik

       
Danny T.'s avatar
Danny T.
426 posts
15 years ago
Danny T.'s avatar Danny T.

Chiming in a bit late to this game — I was wondering if this is compatible with Low’s Seg2Cat, I’m aware you’re a fan of the plugin Ryan, so just wanted to know.

       
1 2

Reply

Sign In To Reply

ExpressionEngine Home Features Pro Contact Version Support
Learn Docs University Forums
Resources Support Add-Ons Partners Blog
Privacy Terms Trademark Use License

Packet Tide owns and develops ExpressionEngine. © Packet Tide, All Rights Reserved.