I have setup Codeigniter on my server and I installed Grocery crud on it. Unfortunately server is windows based and does not support url rewriting and I am stuck using Grocery crud with it.
Can someone explain the solution to this, as I searched grocery crud forum and found nothing.
Regards
Create a file named web.config
in your web root and place the following into the file
<?xml version="1.0" encoding="UTF-8"?>
<configuration>
<system.webServer>
<rewrite>
<rules>
<rule name="Rewrite to index.php">
<match url="index.php|robots.txt|images|test.php" />
<action type="None" />
</rule>
<rule name="Rewrite CI Index">
<match url=".*" />
<conditions>
<add input="{REQUEST_FILENAME}" pattern="css|js|jpg|jpeg|png|gif|ico|htm|html" negate="true" />
</conditions>
<action type="Rewrite" url="index.php/{R:0}" />
</rule>
</rules>
</rewrite>
</system.webServer>
</configuration>
The above is the example used on the Codeigniter Forums here .
You may also need to ensure that $config['uri_protocol']
is set to AUTO
Change config file in CodeIgniter and change $config['querystring'] = false
Now you can access GroceryCrud library functions like this www.example.com/index.php/ControllerClass/FunctionName
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.