View Full Version : Mod Rewrite help

10-19-2010, 07:40 PM
Ok before i start im gonna say im 100% new to this.

Im trying to make it so on my site instead of eg.index.php?page=news&article=firstarticle or something like that it says index?news-first-article.

I've been told to look at Apache rewrite, i've looked through http://httpd.apache.org/docs/2.0/misc/rewriteguide.html but thats completely baffled me. Anyone who can give me a really basic beginners guide i would be most grateful.


10-20-2010, 11:30 AM
RewriteRule ^index\?([_A-Za-z0-9-]+)-article-([_A-Za-z0-9-]+)$ index.php?page=$1&article=$2 [L,nc]

This should rewrite index?news-article-first-article in index.php?page=news&article=first-article