This is a discussion on I erased contact_us.php! within the osCommerce 2.2 Modification Help forums, part of the osCommerce 2.2 Forums category; Please help me anyone! could someone send me the code for contact_us.php? I tried to edit mine, and now its ...
| |||||||
| Register | FAQ | Members List | Calendar | Mark Forums Read |
|
#1
| |||
| |||
| Please help me anyone! could someone send me the code for contact_us.php? I tried to edit mine, and now its disappeared! Only a blank page! I dont know what happened. I backed up only half my files- i thought I had them all- Please someone send me the code so I can paste it back into my file! THANK YOU! |
|
#2
| |||
| |||
| <?php /* $Id: contact_us.php,v 1.42 2003/06/12 12:17:07 hpdl Exp $ osCommerce, Open Source E-Commerce Solutions http://www.oscommerce.com Copyright (c) 2003 osCommerce Released under the GNU General Public License */ require('includes/application_top.php'); require(DIR_WS_LANGUAGES . $language . '/' . FILENAME_CONTACT_US); $page_query = tep_db_query("select pages_id, pages_title, pages_html_text, status from " . TABLE_PAGES . " where pages_title = 'Contact Us'"); $page_check = tep_db_fetch_array($page_query); $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)); $content = CONTENT_CONTACT_US; require(DIR_WS_TEMPLATES . TEMPLATENAME_MAIN_PAGE); require(DIR_WS_INCLUDES . 'application_bottom.php'); ?>
__________________ Google says be nice! |
|
#3
| |||
| |||
| This code does not work for me, I get these errors: -------------------------------------------------------------------------------- Warning: session_start(): Cannot send session cookie - headers already sent by (output started at /home/baby/public_html/osCommerce/contact_us.php:3) in /home/baby/public_html/osCommerce/includes/functions/sessions.php on line 67 Warning: session_start(): Cannot send session cache limiter - headers already sent (output started at /home/baby/public_html/osCommerce/contact_us.php:3) in /home/baby/public_html/osCommerce/includes/functions/sessions.php on line 67 1146 - Table 'baby_osc1.TABLE_PAGES' doesn't exist select pages_id, pages_title, pages_html_text, status from TABLE_PAGES where pages_title = 'Contact Us' [TEP STOP] --------------------------------------------------------------------- What does this mean? Anybody know? |
|
#4
| ||||
| ||||
| It more than likely means you have a space or blank line after the last '?>' or before the first '<?php'
__________________ JPF - osCMax Fourm Moderator Try out our osCMax at: Live Catalog Demo Limited access Admin: Live Admin Demo Feel free to add products they way you want and then purchase them -=+=- Sorry nothing will be billed or shipped! |
|
#5
| |||
| |||
| Sorry about the cross posting- I cant believe all those errors were caused by a few spaces- BUT there is still one more left: ----------------------------------------------------------------- 1146 - Table 'baby_osc1.TABLE_PAGES' doesn't exist select pages_id, pages_title, pages_html_text, status from TABLE_PAGES where pages_title = 'Contact Us' [TEP STOP] ------------------------------------------------------------------------ Its really the first line I dont understand. It must be being generated by the code right underneath it, but I cant put two and two together here- this is my first experience working with php- Any thoughts? |
|
#6
| ||||
| ||||
| Sounds like your site is not totally installed properly. Try RE-UPLOADING all files (except configure.php files). and/or re-do the install part and re-import your Database (make sure you clear it out first or use a new BLANK database).
__________________ JPF - osCMax Fourm Moderator Try out our osCMax at: Live Catalog Demo Limited access Admin: Live Admin Demo Feel free to add products they way you want and then purchase them -=+=- Sorry nothing will be billed or shipped! |
|
#7
| |||
| |||
| I got is working, Thanks! |
| Thread Tools | |
| |
| ||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Spam flaw in stock contact_us.php | neil | osCMax v2 Customization/Mods | 0 | 09-14-2005 05:57 PM |
| Add checkboxes to contact_us.php | nelsonlo | osCMax v1.7 Discussion | 0 | 06-23-2004 04:14 PM |
| editing contact_us | frobscottle | osCommerce 2.2 Modification Help | 3 | 01-26-2004 09:14 AM |
| Adding new text fields to Contact_Us page | mac | osCommerce 2.2 Modification Help | 1 | 05-03-2003 06:20 AM |