Plugin

EE 1
EE 2
Any Segment

Developer

Nicolas Bottari

3rd Party (Free)


Compatibility

  • LG Addon Updater
  • Multi Site Manager
  • Stand Alone Entry Form

Requirements

  • jQuery for the Control Panel

Tags

A plugin that can be used with ExpressionEngine conditionals which returns TRUE if a specified string is found in any segment.

Does this happen to you?

Your templates are accessible on your site with or without the default template group:

  • yoursite.com/index.php/en/blog
  • yoursite.com/index.php/blog

But you have conditionals in your template targeting specific segments:

{if segment_2 == "blog"}

What happens if en is not part of the URL? “blog” may not be in segment_2. In this case, the any_segment plugin would look at all segments and return true if any segment contains “blog”.

Sample Usage

{if {exp:any_segment equals="projects"}}
  ...Show content ...
{/if}

Works with simple conditional if, if:elseif, if:else tags

Any Segment Links

This entry was last updated December 10, 2011, 7:37 am.

Disclaimer: Information about ExpressionEngine add-ons is provided as a service to you, the user, and every member of the ExpressionEngine community. Devot:ee is not responsible if you hose, mangle, wreck, or otherwise destroy your EE website by installing an add-on that you found out about at this site, regardless of its rating, Favorites status, commercial or free status, or general popularity. Caveat EEmptor!

There are no reviews for this add-on yet.

What are you waiting for? Rate it and review it!