Welcome Guest, Not a member yet? Register   Sign In
Dynamic pages, best practices for routing/parsing
#1

[eluser]Unknown[/eluser]
Hi there.

I'm a long-time PHP developer currently developing my first website in CI and so far been enjoying myself. The website is a multilanguage one that will sport dynamic pages (articles ordered in subcategories) mixed with a couple static methods.

I have a couple (6-8 per language) static methods in my controller that are not articles.

The url's for these are are for example:
website.se/se/products/
website.se/se/contact/
and for russian
website.se/ru/products/
website.se/ru/contact/

While articles could be:
website.se/se/article-number-one/

Other than that I want to redirect all other requests to the "se"-controller (or en/ru depending on language) article_loader method. Whats the best practice concerning this? I've looked into routes but it seems like alot of work to map up all the static methods as a route just to exclude them from a route like:

$route['se/(.*)'] = 'se/article_loader/$1';

Is there a better way to resolve this?


Messages In This Thread
Dynamic pages, best practices for routing/parsing - by El Forum - 08-05-2008, 03:22 AM
Dynamic pages, best practices for routing/parsing - by El Forum - 08-05-2008, 05:11 AM
Dynamic pages, best practices for routing/parsing - by El Forum - 08-05-2008, 05:23 AM
Dynamic pages, best practices for routing/parsing - by El Forum - 08-05-2008, 05:31 AM
Dynamic pages, best practices for routing/parsing - by El Forum - 08-05-2008, 05:34 AM
Dynamic pages, best practices for routing/parsing - by El Forum - 08-13-2008, 02:21 AM



Theme © iAndrew 2016 - Forum software by © MyBB