From ef4f209683bb889a077021ba3e54541e1e7b5134 Mon Sep 17 00:00:00 2001 From: cash Date: Thu, 20 Jan 2011 01:29:10 +0000 Subject: adding 'action' to url when overriding the form action git-svn-id: http://code.elgg.org/elgg/trunk@7887 36083f99-b078-4883-b0ff-0f9b5a30f544 --- engine/lib/views.php | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'engine') diff --git a/engine/lib/views.php b/engine/lib/views.php index c97a214a1..ef1fe984d 100644 --- a/engine/lib/views.php +++ b/engine/lib/views.php @@ -1165,6 +1165,10 @@ function elgg_view_listing($icon, $info) { function elgg_view_form($action, $form_vars = array(), $body_vars = array()) { global $CONFIG; + if (isset($form_vars['action'])) { + $form_vars['action'] = "action/{$form_vars['action']}"; + } + $defaults = array( 'action' => $CONFIG->wwwroot . "action/$action", 'body' => elgg_view("forms/$action", $body_vars), -- cgit v1.2.3