cookie monster Posted April 12, 2008 Share Posted April 12, 2008 Hi guys, Seems the Continue button on my Contact page is not working, i have tried a few remedies; replaceing the file, looking at other templates code and matching them up. Nothing seems to work... could someone help out here?? Many Thanks! My cart address is: http://directbmx.co.za/catalog/contact_us.php Code: <?php /* $Id: contact_us.php,v 1.42 2003/06/12 12:17:07 hpdl Exp $ E-Commerce Solutions Copyright (c) 2005 www.flash-template-design.com Released under the GNU General Public License */ require('includes/application_top.php'); require(DIR_WS_LANGUAGES . $language . '/' . FILENAME_CONTACT_US); $error = false; if (isset($HTTP_GET_VARS['action']) && ($HTTP_GET_VARS['action'] == 'send')) { $name = tep_db_prepare_input($HTTP_POST_VARS['name']); $email_address = tep_db_prepare_input($HTTP_POST_VARS['email']); $enquiry = tep_db_prepare_input($HTTP_POST_VARS['enquiry']); if (tep_validate_email($email_address)) { tep_mail(STORE_OWNER, STORE_OWNER_EMAIL_ADDRESS, EMAIL_SUBJECT, $enquiry, $name, $email_address); tep_redirect(tep_href_link(FILENAME_CONTACT_US, 'action=success')); } else { $error = true; $messageStack->add('contact', ENTRY_EMAIL_ADDRESS_CHECK_ERROR); } } $breadcrumb->add(NAVBAR_TITLE, tep_href_link(FILENAME_CONTACT_US)); ?> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html <?php echo HTML_PARAMS; ?>> <head> <meta http-equiv="Content-Type" content="text/html; charset=<?php echo CHARSET; ?>"> <title><?php echo TITLE; ?></title> <base href="<?php echo (($request_type == 'SSL') ? HTTPS_SERVER : HTTP_SERVER) . DIR_WS_CATALOG; ?>"> <link rel="stylesheet" type="text/css" href="style.css"> </head> <body marginwidth="0" marginheight="0" topmargin="0" bottommargin="0" leftmargin="0" rightmargin="0"> <!-- header //--> <?php require(DIR_WS_INCLUDES . 'header.php'); ?> <!-- header_eof //--> <!-- body //--> <tr> <td width="182" align="left" valign="top"> <table width="182" cellpadding="0" cellspacing="0" border="0"> <?php require(DIR_WS_INCLUDES . 'column_left.php'); ?> </table> </td> <td width="509" valign="top" style="padding-left:2px;"> <table border="0" cellpadding="0" cellspacing="0" width="100%"> <tr> <td width="100%" height="100%" valign="top" bgcolor="#FFFFFF"> <table border="0" width="100%" cellpadding="0" cellspacing="0" > <tr> <td width="100%" height="25" valign="top"> <table width="100%" border="0" cellpadding="0" cellspacing="0" height="24"> <tr> <td><img src="images/left_header.gif" width="4" height="24" alt="" /></td> <td width="100%" style="background-image:url(images/header_bg.gif); text-align:left; color:#FFF; padding-left:5px; font-size:110%; font-weight:bold "><?php echo HEADING_TITLE; ?> </td> <td><img src="images/right_header.gif" width="4" height="24" alt="" /></td> </tr> </table> </td> </tr> <tr> <td valign="top" height="409" style="padding:0px 5px; " class="infoBox"> <table border="0" cellpadding="0" cellspacing="0" width="100%"> <td><?php echo tep_draw_separator('pixel_trans.gif', '100%', '1'); ?></td> </tr> <?php if ($messageStack->size('contact') > 0) { ?> <tr> <td><?php echo $messageStack->output('contact'); ?></td> </tr> <tr> <td><?php echo tep_draw_separator('pixel_trans.gif', '100%', '10'); ?></td> </tr> <?php } if (isset($HTTP_GET_VARS['action']) && ($HTTP_GET_VARS['action'] == 'success')) { ?> <tr> <td> <table border="0" width="100%" cellspacing="0" cellpadding="0" > <tr> <td class="main" align="center"><?php echo TEXT_SUCCESS; ?></td> </tr> <tr> <td><?php echo tep_draw_separator('pixel_trans.gif', '100%', '10'); ?></td> </tr> <tr> <td align="left"><table border="0" width="100%" cellspacing="1" cellpadding="2" > <tr class="infoBoxContents"> <td><table border="0" width="100%" cellspacing="0" cellpadding="2"> <tr> <td width="10"><?php echo tep_draw_separator('pixel_trans.gif', '10', '1'); ?></td> <td align="right"><?php echo '<a href="' . tep_href_link(FILENAME_DEFAULT) . '">' . tep_image_button('button_continue.gif', IMAGE_BUTTON_CONTINUE) . '</a>'; ?></td> <td width="10"><?php echo tep_draw_separator('pixel_trans.gif', '10', '1'); ?></td> </tr> </table></td> </tr> </table></td> </tr> </table></td></tr> <?php } else { ?> <tr> <td align="left" ><table border="0" width="100%" cellspacing="1" cellpadding="2"> <tr class="infoBoxContents"> <td width="100%" style="padding:5px; "><table border="0" width="100%" cellspacing="0" cellpadding="2"> <tr> <td class="main" ><?php echo ENTRY_NAME; ?></td> </tr> <tr> <td class="main"><?php echo tep_draw_input_field('name'); ?></td> </tr> <tr> <td class="main" ><?php echo ENTRY_EMAIL; ?></td> </tr> <tr> <td class="main"><?php echo tep_draw_input_field('email'); ?></td> </tr> <tr> <td class="main" ><?php echo ENTRY_ENQUIRY; ?></td> </tr> <tr> <td align="left" style="padding-left:3px; "><?php echo tep_draw_textarea_field('enquiry', 'soft', 30, 7); ?></td> </tr> </table></td> </tr> <tr> <td><?php echo tep_draw_separator('pixel_trans.gif', '100%', '10'); ?></td> </tr> <tr> <td colspan="2"><table border="0" width="100%" cellspacing="1" cellpadding="2" > <tr class="infoBoxContents"> <td align="left"><table border="0" width="180" cellspacing="0" cellpadding="2"> <tr> <td width="10"><?php echo tep_draw_separator('pixel_trans.gif', '10', '1'); ?></td> <td align="right"><?php echo tep_image_submit('button_continue.gif', IMAGE_BUTTON_CONTINUE); ?></td> <td width="10"><?php echo tep_draw_separator('pixel_trans.gif', '10', '1'); ?></td> </tr> </table></td> </tr> </table></td> </tr> <tr> <td><?php echo tep_draw_separator('pixel_trans.gif', '100%', '10'); ?></td> </tr> <tr> <td colspan="2" height="1" background="images/hpoint.gif" align="left"><img src="images/hpoint.gif" width="3" height="1" alt=""></td> </tr> <tr> <td colspan="2" height="1" background="images/hpoint.gif" align="left" style="margin-top:2px;"><img src="images/hpoint.gif" width="3" height="1" alt=""></td> </tr> <tr> <td colspan="2" align="left"> <Table border="0" cellpadding="0" cellspacing="0" > <tr align="left"> <td width="50%" style="padding-left:20px;"><br/><span style="font-weight:bold;">Phone:</span> 1-800-555-55-55<br> <br/> <span style="font-weight:bold;">Fax:</span> 1-800-555-55-55</td> <td width="50%" style="padding-left:20px;"> <br/><span style="font-weight:bold;">E-mail:</span> [email protected]<br> <br/> <span style="font-weight:bold;">Toll Free:</span> 1-800-555-55-55</td> </tr></table></td> </tr> </table></td> </tr> <?php } ?> </table></td></tr> </table></td> </form> </tr> </table> </td> </tr> <!-- body_eof //--> <!-- footer //--> <?php require(DIR_WS_INCLUDES . 'footer.php'); ?> <!-- footer_eof //--> </body> </html> <?php require(DIR_WS_INCLUDES . 'application_bottom.php'); ?> Link to comment Share on other sites More sharing options...
germ Posted April 12, 2008 Share Posted April 12, 2008 You're missing the beginning <form...> tag. Find this code: <tr> <td align="left" ><table border="0" width="100%" cellspacing="1" cellpadding="2"> <tr class="infoBoxContents"> <td width="100%" style="padding:5px; "><table border="0" width="100%" cellspacing="0" cellpadding="2"> <tr> <td class="main" ><?php echo ENTRY_NAME; ?></td> </tr> <tr> Change it to this: <tr> <td align="left" > <?php echo tep_draw_form('contact_us', tep_href_link(FILENAME_CONTACT_US, 'action=send')); ?> <table border="0" width="100%" cellspacing="1" cellpadding="2"> <tr class="infoBoxContents"> <td width="100%" style="padding:5px; "><table border="0" width="100%" cellspacing="0" cellpadding="2"> <tr> <td class="main" ><?php echo ENTRY_NAME; ?></td> </tr> <tr> All I did was move this code onto a line by itself: <table border="0" width="100%" cellspacing="1" cellpadding="2"> And inserted this PHP code above it: <?php echo tep_draw_form('contact_us', tep_href_link(FILENAME_CONTACT_US, 'action=send')); ?> If I suggest you edit any file(s) make a backup first - I'm not perfect and neither are you. "Given enough impetus a parallelogramatically shaped projectile can egress a circular orifice." - Me - "Headers already sent" - The definitive help "Cannot redeclare ..." - How to find/fix it SSL Implementation Help Like this post? "Like" it again over there > Link to comment Share on other sites More sharing options...
MJP Posted April 12, 2008 Share Posted April 12, 2008 there is no opening form set with a send action . you're missing: <?php echo tep_draw_form('contact_us', tep_href_link(FILENAME_CONTACT_US, 'action=send')); ?> look at a clean contact_us.php file and you'll see what code you're missing. Link to comment Share on other sites More sharing options...
cookie monster Posted April 12, 2008 Author Share Posted April 12, 2008 many thanks, works perfect now. Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.