CodeIgniter Forums

Full Version: Help set up routes
You're currently viewing a stripped down version of our content. View the full version with proper formatting.

I have a URL like:


And set up routes:
$route['([^.]+)/?'] = 'structure/view/$1';

According to this rule, I get only the first section: news.
How do I get the last instead of the first section, like:
* videos
* pictures
* reviews

my .htaccess file:

AddDefaultCharset UTF-8

Options +FollowSymLinks
Options -Indexes

DirectoryIndex index.php

RewriteEngine on
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ /index.php/$1 [L,QSA]