Add thenew fields in contact.htm
then go in admin/modules/oxymall/plugins/site.contact.php
( this works only for non required fields )
go to line 178 and add the new vars
$vars["new_var"] = stripslashes($_POST["new_var"]);
$vars["new_var2"] = stripslashes($_POST["new_var2"]);
Then go in admin->contact->module settings->email notifications and add this new variables in the message body {NEW_VAR} and {NEW_VAR2}
Optional
To have them saved in the database you need to add the new variables as fields to site_oxymall_plugins_contact_messages ( add 2 varchar fields new_var and new_var2 )
Then edit the following lines
Code:
$id = $this->db->QueryInsert(
$this->tables["plugin:contact_messages"],
$contact = array(
"module_id" => $this->tpl_module["mod_id"],
"item_new" => 1,
"item_date" => time(),
"item_email" => $vars["email"],
"item_name" => $vars["name"],
"item_subject" => $vars["subject"],
"item_message" => $vars["message"],
"item_department" => $vars["regarding"],
"new_var" => $vars["new_var"],
"new_vars2" => $vars["new_var2"]
)
);
Then go in admin/modules/oxymall/plugins/forms/contact/items/
open add.xml
after <item_message type="text" title="Message"/>
add your new variables
<new_var type="text" title="New Var"/>
<new_var2 type="text" title="New Var2"/>
I hope i covered everything.
Bookmarks