English Post your requirements here

Bernard - Shorter URLS :)

http://www.ngr78.co.uk/article....php/17/pages/2 rewritten to:

www.ngr78.co.uk/articles/view/17/pages/2 Give it a try

Requires this rewrite rule:

RewriteCond %{REQUEST_FILENAME} !-d RewriteCond %{REQUEST_FILENAME} !-f RewriteRule ([^0-9]+)/([0-9]+) $1.php/$2 [L]

This needs to be placed before RewriteRule .* - [E=REMOTE_USER:%{HTTP:Authorization},L]

eg:

# translate authentication data if PHP runs as CGI -- see agents/feed.php #

RewriteEngine on

RewriteCond %{REQUEST_FILENAME} !-d RewriteCond %{REQUEST_FILENAME} !-f RewriteRule ([^0-9]+)/([0-9]+) $1.php/$2 [L] RewriteRule .* - [E=REMOTE_USER:%{HTTP:Authorization},L]


To test this we added the following line in global.php:

$path = str_replace('view', 'view.php', $path);

eg

if(isset($_SERVER['REQUEST_URI'])) { $path = str_replace('?'.$_SERVER['QUERY_STRING'], '', $_SERVER['REQUEST_URI']); $path = str_replace('view', 'view.php', $path); if($here = strpos($path, '.php/')) {

Obviously this needs coding correctly for getting the correct filename and generating the correct URLs

Cheers Nick (and a big help from Martyn)