This is a pretty simple question, I just can't seem to find the information on it. In expression engine, is it possible for {segment_1} to be a dynamic variable. I.E. if I wanted to take my URL structure from: http://www.whatever.com/category/football/green-bay/ to: http://www.whatever.com/football/green-bay/ I don't want to actually create the directory for football within my code(as this is just an example, and the amount of base categories is in the hundreds), I just want it to map to my templates/category page.
I know this could probably be accomplished somehow through mod_rewrite, but that's what I'm trying to avoid. I'm trying to see if there's a built in way in Expression Engine to accomplish this.
This sounds like the sort of functionality that the MD Detect Pagetype plugin offers. The plugin "listens" to a certain URL segment to determine what type of page is being displayed. It then gives you access to the following conditionals:
{exp:md_detect_page_type url_segment="{segment_3}"}
{if pagination_page}This is a Paginated Page{/if}
{if category_page}This is a Category Page{/if}
{if yearly_archive_page}This is a Yearly Archive Page{/if}
{/exp:md_detect_page_type}
Visit the website linked above to download and find out more about the free plugin.