New actions for blocks via API

This commit is contained in:
Zach Copley
2009-10-09 13:35:54 -07:00
parent ada84698f2
commit 09f4d1ef23
5 changed files with 249 additions and 134 deletions

View File

@@ -474,10 +474,15 @@ class Router
// blocks
$m->connect('api/blocks/:method/:argument',
array('action' => 'api',
'apiaction' => 'blocks'));
$m->connect('api/blocks/create/:id.:format',
array('action' => 'ApiBlockCreate',
'id' => '[a-zA-Z0-9]+',
'format' => '(xml|json)'));
$m->connect('api/blocks/destroy/:id.:format',
array('action' => 'ApiBlockDestroy',
'id' => '[a-zA-Z0-9]+',
'format' => '(xml|json)'));
// help
$m->connect('api/help/test.:format',