<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="http://davidjsmitty.com/blog/utility/FeedStylesheets/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/"><channel><title>David J. Smith's Program : REST</title><link>http://davidjsmitty.com/blog/me/archive/tags/REST/default.aspx</link><description>Tags: REST</description><dc:language>en</dc:language><generator>CommunityServer 2.1 SP2 (Build: 61129.2)</generator><item><title>Using ISAPI_Rewrite Lite with ASP.NET 2 and a dedicated server</title><link>http://davidjsmitty.com/blog/me/archive/2007/07/23/using-isapi-rewrite-lite-with-asp-net-2-and-a-dedicated-server.aspx</link><pubDate>Mon, 23 Jul 2007 14:33:00 GMT</pubDate><guid isPermaLink="false">a7f2cd10-d562-4d23-8785-93d3efa39b1e:459</guid><dc:creator>david</dc:creator><slash:comments>0</slash:comments><comments>http://davidjsmitty.com/blog/me/comments/459.aspx</comments><wfw:commentRss>http://davidjsmitty.com/blog/me/commentrss.aspx?PostID=459</wfw:commentRss><description>&lt;P&gt;Inspired from: &lt;A href="http://www.codinghorror.com/blog/archives/000797.html"&gt;http://www.codinghorror.com/blog/archives/000797.html&lt;/A&gt;&amp;nbsp;and all the websites out there that have nice-looking URLs.&lt;/P&gt;
&lt;P&gt;You have to have a dedicated or virtual dedicated server in order to use IIS plugins such as ISAPI_Rewrite because administrative privilege is required.&amp;nbsp; You can use ASP.NET UrlMappings to a lesser extent in a shared environment, but you're not going to get away from the .aspx page extension.&lt;/P&gt;
&lt;P&gt;Supposing you have a computer you can serve from, and you've installed ASP.NET, you can turn your entire website into a RESTful-&lt;EM&gt;seeming &lt;/EM&gt;site by using the following httpd.ini file.&lt;/P&gt;
&lt;P&gt;Restrictions:&lt;/P&gt;
&lt;OL&gt;
&lt;LI&gt;No .aspx pages may be nested in the root folder&lt;/LI&gt;
&lt;LI&gt;No folders may have a period in them&amp;nbsp;&lt;/LI&gt;&lt;/OL&gt;
&lt;P&gt;&lt;BR&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;[ISAPI_Rewrite]&lt;/P&gt;
&lt;P&gt;# /user&lt;BR&gt;# This turns every .aspx page into a "VERB" sort of page, like&amp;nbsp;&lt;A href="http://piqd.com/upload"&gt;http://piqd.com/upload&lt;/A&gt;&lt;BR&gt;RewriteCond URL (?!.*\.).*&lt;BR&gt;RewriteRule /([^/]*)(.*) /$1.aspx$2&amp;nbsp; &lt;img src="http://davidjsmitty.com/blog/emoticons/emotion-55.gif" alt="Idea" /&gt;&lt;/P&gt;
&lt;P&gt;# /user/q/23&lt;BR&gt;#&amp;nbsp; You can now append GET parameters to the URL with /VERB/PARAMNAME/PARAMVALUE&lt;BR&gt;RewriteRule (.*?\.aspx)(\?[^/]*)?/([^/]*)/([^/]*)(.*) $1(?2$2&amp;amp;:\?)$3=$4$5 [NS,I]&lt;/P&gt;
&lt;P&gt;# /&lt;BR&gt;# If the request is only a /, then redirect to /&lt;BR&gt;RewriteRule /\.aspx / &lt;img src="http://davidjsmitty.com/blog/emoticons/emotion-55.gif" alt="Idea" /&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;img src="http://davidjsmitty.com/blog/aggbug.aspx?PostID=459" width="1" height="1"&gt;</description><category domain="http://davidjsmitty.com/blog/me/archive/tags/Code/default.aspx">Code</category><category domain="http://davidjsmitty.com/blog/me/archive/tags/REST/default.aspx">REST</category></item></channel></rss>