My goal is to create a simple web interface that will allow a user to view and interact with a small MySQL database (not much more than simple CRUD functionality).
After some research, I found this tutorial and began following it:
http://www.angularcode.com/product-inventory-management-using-angularjs-mysql-and-php-restful-api/
However, as everyone in the comment section will tell you, out-of-the-box it will not load. The creator of the tutorial told everyone to enable mod_rewrite on their web server and that would fix the issue. However, I'm using visual studio and IIS, not a local Apache server.
The .HTACCESS file given in the demo is as follows:
RewriteEngine On
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^(.*)$ %{ENV:BASE}index.php [QSA,L]
I assume (someone please correct me if I'm wrong, I am new at this), that I'll need to replicate that same functionality in my web.config file instead. My first attempt at this is here:
<configuration>
<system.web>
<compilation debug="true" targetFramework="4.5" />
<httpRuntime targetFramework="4.5" />
</system.web>
<system.webServer>
<rewrite>
<rules>
<rule name="Imported Rule 1" stopProcessing="true">
<match url="^(.*)$" ignoreCase="false" />
<conditions>
<add input="{REQUEST_FILENAME}" matchType="IsFile" ignoreCase="false" negate="true" />
</conditions>
<action type="Rewrite" url="index.php?q={R:1}" appendQueryString="true" />
</rule>
</rules>
</rewrite>
</system.webServer>
</configuration>
However, this does not work. After making these changes, I now get a 404 ("Requested URL http://localhost:59438/index.php?q= ").
At this point I fear I have already spent more time than I should have fighting this portion of the tutorial that has little to nothing to do with the skills I'm attempting to practice (though I guess that is just par for the course).
If someone could take a look at what I'm doing wrong, or supply a workaround so I can actually get started with this, I would be eternally grateful.