HT access trials and tribs

The rewrite engine should show a pretty url....is it working?

Great primer site: http://www.addedbytes.com/articles/for-beginners/url-rewriting-for-beginners/

A couple of notes:

  1. I use Vhosts for local testing (keeps paths nice and production-like) - and directed the error log file in the vhosts configuration to go a separate local directory - so I could see why I was having a problem. ErrorLog "C:/vhosts/advphp/logs/error.log"
  2. That led me to understanding that the rerwrite base was part of the culprit - moved from ch2 to / and it worked. But..
  3. The duh (or if I'm kind to myself, aha) moment is from this post on Larry's forum: http://www.larryullman.com/forums/index.php?/topic/1964-mod-rewrite-chapter/ (nice url...) and you need to change your href links to the new "pretty" links if you want them to show in the browser address line. Thus, no href ="ch2/index.php?p=about.php", but rather href="ch2/about". This is practically errata material for newbies to this topic (like me) - small, but critical - it was working the whole time - but I didn't have any proper links to "test" or show it.

Thus, You can link here two ways:

 

About Dirty or About Clean
Toggle Sidebar