Well, I managed to sort out the code for rewriting the url at both the server level and within this CMS. I have currently only rewritten it for the articles, but I should be able to apply it to the rest of the website at my leisure.
To be honest, it wasn't really that difficult when I finally applied myself, but there was an initial case of headscratching as I tried to work out how to get it to work.
If anyone is interested on how to use the .htaccess to rewrite simple urls let me know. Most of the tutorials I read were far too complicated, and I ended up working it out through trial and error.
And to think, one of my old lecturers used to accuse me of being a code hacker rather than a programmer at Uni - what did he know?!
--Added--
So a number of people are looking for some basic code in order to be able to start using mod rewrite in an .htaccess file for their own site.
The following is what I would use in order to change a file story.php?id=007 into the more friendly form story/007.html:
RewriteEngine on
RewriteRule ^story/(.*).html$ /story.php?id=$1 [NC,L]
For further reading, I highly recommend this introduction over at Webmaster World.
|