mirror of
https://github.com/EGroupware/egroupware.git
synced 2024-12-26 00:29:18 +01:00
allow to preset variables via get parameters
This commit is contained in:
parent
23aea3864c
commit
016a1cadde
@ -60,6 +60,11 @@ class addressbook_contactform
|
||||
*/
|
||||
function display_var(array &$content=null,$addressbook=null,$fields=null,$msg=null,$email=null,$tpl_name=null,$subject=null,$copytoreceiver=false,$sel_options=array())
|
||||
{
|
||||
// allow to preset variables via get parameters
|
||||
if ($_SERVER['REQUEST_METHOD'] == 'GET')
|
||||
{
|
||||
$content = array_merge($_GET, (array)$content);
|
||||
}
|
||||
#error_log( "<p>addressbook_contactform::display(".print_r($content,true).",$addressbook,".print_r($fields,true).",$msg,$tpl_name)</p>\n");
|
||||
if (empty($tpl_name) && !empty($content['tpl_form_name'])) $tpl_name =$content['tpl_form_name'];
|
||||
$tpl = new etemplate($tpl_name ? $tpl_name : 'addressbook.contactform');
|
||||
|
Loading…
Reference in New Issue
Block a user