Skip to content

Commit 3ad1829

Browse files
authored
Update README.md
1 parent ea97729 commit 3ad1829

File tree

1 file changed

+20
-1
lines changed

1 file changed

+20
-1
lines changed

README.md

+20-1
Original file line numberDiff line numberDiff line change
@@ -1562,7 +1562,26 @@ To run the functional tests locally you may run the following commands:
15621562
This runs the functional tests from the "tests" directory. It uses the database dumps (fixtures) and
15631563
database configuration (config) from the corresponding subdirectories.
15641564

1565-
## Nginx config example
1565+
## Pretty URL
1566+
1567+
You may "rewrite" the URL to remove the "api.php" from the URL.
1568+
1569+
### Apache config example
1570+
1571+
Enable mod_rewrite and add the following to your ".htaccess" file:
1572+
1573+
```
1574+
RewriteEngine On
1575+
RewriteCond %{REQUEST_FILENAME} !-d
1576+
RewriteCond %{REQUEST_FILENAME} !-f
1577+
RewriteRule ^(.*)$ api.php/$1 [L,QSA]
1578+
```
1579+
1580+
The ".htaccess" file needs to go in the same folder as "api.php".
1581+
1582+
### Nginx config example
1583+
1584+
Use the following config to serve the API under Nginx and PHP-FPM:
15661585

15671586
```
15681587
server {

0 commit comments

Comments
 (0)