New Zenner
- Join Date:
- Mar 2010
- Location:
- NY - Hudson Valley
- Posts:
- 30
- Plugin Contributions:
- 0
make a form to go to a different email address
Hi,
I've copied the contact form in order to make an additional and different type of form. It's all working well BUT... I need the form to go to a different email address than the original contact form.
Does anyone know how to hardcode for that? Currently the contact form goes to a drop down list (set in the Admin). Is there a way to delete the code from the new tpl_newform.php and just hard code an address or two?
Here are the 2 page areas that I think need help:
tpl_pagename_default.php
v<?php
// show dropdown if set
if (CONTACT_US_LIST !=''){
?>
<label class="inputLabel" for="send-to"><?php echo SEND_TO_TEXT; ?></label>
header.php (for the new page)
// use contact us dropdown if defined
if (CONTACT_US_LIST !=''){
$send_to_array=explode("," ,CONTACT_US_LIST);
preg_match('/<[^>]+>/', $send_to_array[$_POST['send_to']], $send_email_array);
$send_to_email= eregi_replace (">", "", $send_email_array[0]);
$send_to_email= eregi_replace ("<", "", $send_to_email);
$send_to_name = preg_replace('/<[^]/', '', $send_to_array[$_POST['send_to']]);
} else { //otherwise default to EMAIL_FROM and store name
$send_to_email = EMAIL_FROM;
$send_to_name = STORE_NAME;
}
Maybe I'm way off?! :blink: Thanks.