<?xml version="1.0"?>
<rss version="2.0">
  <channel>
    <title>PHPDeveloper.org</title>
    <link>http://www.phpdeveloper.org</link>
    <description>Up-to-the Minute PHP News, views and community</description>
    <language>en-us</language>
    <pubDate>Thu, 23 May 2013 06:01:36 -0500</pubDate>
    <ttl>30</ttl>
    <item>
      <title><![CDATA[CodeSnipers.com: Building Clean URLs Into a Site]]></title>
      <guid>http://www.phpdeveloper.org/news/5706</guid>
      <link>http://www.phpdeveloper.org/news/5706</link>
      <description><![CDATA[<p>
On CodeSnipers.com today, <i>Peter Harkins</i> <a href="http://codesnipers.com/?q=node/420&title=">talks about</a> a method, using regular expressions and Apache to turn ugly, GET-laden URLs in your application into clean, search engine friendly URLs without altering the underlying scripts.
</p>
<blockquote>
So we have two goals. First, requests for the new URL are internally rewritten to call the existing scripts without users ever knowing they exist. Second, requests for the old URLs get a 301 redirect to the new URLs so that search engines and good bookmarks immediately switch to the new URLs.
</blockquote>
<p>
He <a href="http://codesnipers.com/?q=node/420&title=">starts</a> with a sample .htaccess file, showing a simple RewriteRule to take in the request and remap them back to the old PHP script's input format. They work through a few more changes, noting issues along the way (in case you hit them too) and end up with a simple, and much easier way to achieve clean URL bliss.
</p>]]></description>
      <pubDate>Tue, 27 Jun 2006 15:00:14 -0500</pubDate>
    </item>
  </channel>
</rss>
