CRUD API Documentation

create.php
read.php
update.php
delete.php

RewriteRule ^/?([-A-Za-z0-9]+)/([-A-Za-z0-9]+)/? /list.php?db=$1&table=$2 [L]
RewriteRule ^/?([-A-Za-z0-9]+)/([-A-Za-z0-9]+)/([0-9]+)/? /read.php?db=$1&table=$2&key=$3 [L]

Hmm, it might be a bad idea to use the default URL for a table to indicate a list or a read, because that's probably the URL I will want to use for the CRUD user-interface. In fact, I might want to change the dump URL as well.

/dump/database
/read/database/table
/read/database/table/key

Is there standard URL structure for this kind of stuff?

dump.php


Huh. I need to learn how to leverage different HTTP methods for my different URLs.

So, can my RewriteRules differentiate between different HTTP methods? Or should I have just one big script for all of these? I guess I could do that, especially since most have common stuff (like connecting to the database server and reading the table configuration).