ballantine Posted November 22, 2004 Posted November 22, 2004 Warning: session_start(): Cannot send session cookie - headers already sent by (output started at E:\hshome\ballanti\ballantinehobbies.com\admin\includes\configure.php:2) in E:\hshome\ballanti\ballantinehobbies.com\admin\includes\functions\sessions.php on line 67 Warning: session_start(): Cannot send session cache limiter - headers already sent (output started at E:\hshome\ballanti\ballantinehobbies.com\admin\includes\configure.php:2) in E:\hshome\ballanti\ballantinehobbies.com\admin\includes\functions\sessions.php on line 67
Guest Posted November 22, 2004 Posted November 22, 2004 Remove the whitespace at the end of the file after the end tag ?>
ballantine Posted November 22, 2004 Author Posted November 22, 2004 is this rigth then i put it in both catalog and admin <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN"> <?php /* $Id: configure.php,v 1.4 2003/10/01 09:08:17 serg Exp $ osCommerce, Open Source E-Commerce Solutions http://www.oscommerce.com Copyright © 2003 osCommerce Released under the GNU General Public License */ // Define the webserver and path parameters // * DIR_FS_* = Filesystem directories (local/physical) // * DIR_WS_* = Webserver directories (virtual/URL) define('HTTP_SERVER', ''); // eg, http://localhost - should not be empty for productive servers define('HTTPS_SERVER', ''); // eg, https://localhost - should not be empty for productive servers define('ENABLE_SSL', false); // secure webserver for checkout procedure? define('HTTP_COOKIE_DOMAIN', ''); define('HTTPS_COOKIE_www.ballantinehobbies.com', ''); define('HTTP_COOKIE_PATH', ''); define('HTTPS_COOKIE_PATH', ''); define('DIR_WS_HTTP_CATALOG', '/catalog/'); define('DIR_WS_HTTPS_CATALOG', '/catalog/'); define('DIR_WS_IMAGES', '/catalog/images/'); define('DIR_WS_ICONS', DIR_WS_IMAGES . 'icons/'); define('DIR_WS_INCLUDES', 'includes/'); define('DIR_WS_BOXES', DIR_WS_INCLUDES . 'boxes/'); define('DIR_WS_FUNCTIONS', DIR_WS_INCLUDES . 'functions/'); define('DIR_WS_CLASSES', DIR_WS_INCLUDES . 'classes/'); define('DIR_WS_MODULES', DIR_WS_INCLUDES . 'modules/'); define('DIR_WS_LANGUAGES', DIR_WS_INCLUDES . 'languages/'); define('DIR_WS_DOWNLOAD_PUBLIC', 'pub/'); define('DIR_FS_CATALOG', dirname($HTTP_SERVER_VARS['SCRIPT_FILENAME'])); define('DIR_FS_DOWNLOAD', DIR_FS_CATALOG . 'download/'); define('DIR_FS_DOWNLOAD_PUBLIC', DIR_FS_CATALOG . 'pub/'); // define our database connection define('DB_SERVER', ''); // eg, localhost - should not be empty for productive servers define('DB_SERVER_USERNAME', ''); define('DB_SERVER_PASSWORD', ''); define('DB_DATABASE', 'osCommerce'); define('USE_PCONNECT', 'false'); // use persistent connections? define('STORE_SESSIONS', ''); // leave empty '' for default handler or set to 'mysql' ?><HTML><HEAD> <META name="GENERATOR" content="IBM NetObjects TopPage V4.0.3 for Windows"></HEAD> <BODY></BODY>
Guest Posted November 22, 2004 Posted November 22, 2004 The configure.php files should be everything between the PHP tags <? ?> and not the other HTML tags. That is the cause of your problems...
Guest Posted November 22, 2004 Posted November 22, 2004 if you want to do it the way you have it partially listed, you have to use this format: <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> <html> <head> <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1"> <title>Untitled Document</title> </head> <body> php code goes here . .. </body> </html>
ballantine Posted November 22, 2004 Author Posted November 22, 2004 i am still having problems ,after i fill in my info it kicks me out but is showing secure lock,is there anything else i have to fill in on the configure.php this is the message i am getting after the kick out Warning: mail(): Failed to connect to mailserver at "localhost" port 25, verify your "SMTP" and "smtp_port" setting in php.ini or use ini_set() in E:\hshome\ballanti\ballantinehobbies.com\catalog\includes\classes\email.php on line 500 Warning: Cannot modify header information - headers already sent by (output started at E:\hshome\ballanti\ballantinehobbies.com\catalog\includes\classes\email.php:500) in E:\hshome\ballanti\ballantinehobbies.com\catalog\includes\functions\general.php on line 29 <?php /* $Id: configure.php,v 1.4 2003/10/01 09:08:17 serg Exp $ osCommerce, Open Source E-Commerce Solutions http://www.oscommerce.com Copyright © 2003 osCommerce Released under the GNU General Public License */ // Define the webserver and path parameters // * DIR_FS_* = Filesystem directories (local/physical) // * DIR_WS_* = Webserver directories (virtual/URL) define('HTTP_SERVER', ''); // eg, http://localhost - should not be empty for productive servers define('HTTPS_SERVER', ''); // eg, https://localhost - should not be empty for productive servers define('ENABLE_SSL', true); // secure webserver for checkout procedure? define('HTTP_COOKIE_www.ballantinehobbies.com', ''); define('HTTPS_COOKIE_www.ballantinehobbies.com', ''); define('HTTP_COOKIE_PATH', ''); define('HTTPS_COOKIE_PATH', ''); define('DIR_WS_HTTP_CATALOG', '/catalog/'); define('DIR_WS_HTTPS_CATALOG', '/catalog/'); define('DIR_WS_IMAGES', '/catalog/images/'); define('DIR_WS_ICONS', DIR_WS_IMAGES . 'icons/'); define('DIR_WS_INCLUDES', 'includes/'); define('DIR_WS_BOXES', DIR_WS_INCLUDES . 'boxes/'); define('DIR_WS_FUNCTIONS', DIR_WS_INCLUDES . 'functions/'); define('DIR_WS_CLASSES', DIR_WS_INCLUDES . 'classes/'); define('DIR_WS_MODULES', DIR_WS_INCLUDES . 'modules/'); define('DIR_WS_LANGUAGES', DIR_WS_INCLUDES . 'languages/'); define('DIR_WS_DOWNLOAD_PUBLIC', 'pub/'); define('DIR_FS_CATALOG', dirname($HTTP_SERVER_VARS['SCRIPT_FILENAME'])); define('DIR_FS_DOWNLOAD', DIR_FS_CATALOG . 'download/'); define('DIR_FS_DOWNLOAD_PUBLIC', DIR_FS_CATALOG . 'pub/'); // define our database connection define('DB_SERVER', ''); // eg, localhost - should not be empty for productive servers define('DB_SERVER_USERNAME', ''); define('DB_SERVER_PASSWORD', ''); define('DB_DATABASE', 'osCommerce'); define('USE_PCONNECT', 'false'); // use persistent connections? define('STORE_SESSIONS', ''); // leave empty '' for default handler or set to 'mysql' ?>
hermes369 Posted November 22, 2004 Posted November 22, 2004 Warning: session_start(): Cannot send session cookie - headers already sent by (output started at /vservers/westafer/htdocs/b/catalog/products_new.php:1) in /vservers/westafer/htdocs/b/catalog/includes/functions/sessions.php on line 67 Warning: session_start(): Cannot send session cache limiter - headers already sent (output started at /vservers/westafer/htdocs/b/catalog/products_new.php:1) in /vservers/westafer/htdocs/b/catalog/includes/functions/sessions.php on line 67 I'm getting the same error and cannot find any hanging whitespace. Is there anything else I can try? Also, I searched every page and cannot find any whitespace. Because of the error, should I only have to look in the listed files (products_new and seesions.php)? Thanks, Benjamin Westafer www.westafer.com/b/catalog/
Guest Posted November 22, 2004 Posted November 22, 2004 Well, look at the beginning of the file... I visited your site and could not see an error. BTW, congrats on the upcoming baby! :)
hermes369 Posted November 22, 2004 Posted November 22, 2004 Well, look at the beginning of the file... I visited your site and could not see an error. BTW, congrats on the upcoming baby! :) <{POST_SNAPBACK}> Thanks! I'm terrified and excited all at once; especially since it's any day now! Click on new products and you should see the error. It doesn't seem to happen anywhere else. Before I go looking through every file, can I restrict my search to those files: products_new.php and sessions.php? While I have you, is there any significance to the numeral after the :pagename, as in products_new.php:1) . Thank you for the quick response! B
Guest Posted November 22, 2004 Posted November 22, 2004 Edit includes/languages/english/products_new.php and remove the white space before and after the PHP tags...
hermes369 Posted November 22, 2004 Posted November 22, 2004 Edit includes/languages/english/products_new.php and remove the white space before and after the PHP tags... <{POST_SNAPBACK}> OK, I know I am now being a pest: contents of languages/english/products_new.php: <?php /* $Id: products_new.php,v 1.3 2002/11/19 01:48:08 dgw_ Exp $ osCommerce, Open Source E-Commerce Solutions http://www.oscommerce.com Copyright (c) 2002 osCommerce Released under the GNU General Public License */ define('NAVBAR_TITLE', 'New Products'); define('HEADING_TITLE', 'New Products'); define('TEXT_DATE_ADDED', 'Date Added:'); define('TEXT_MANUFACTURER', 'Manufacturer:'); define('TEXT_PRICE', 'Price:'); ?> Contents of catalog/products_new.php: <?php /* $Id: products_new.php,v 1.27 2003/06/09 22:35:33 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_PRODUCTS_NEW); $breadcrumb->add(NAVBAR_TITLE, tep_href_link(FILENAME_PRODUCTS_NEW)); ?> <!doctype html public "-//W3C//DTD HTML 4.01 Transitional//EN"> <html <?php echo HTML_PARAMS; ?>> <head> <meta http-equiv="content-type" content="text/html; charset=utf-8"> <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="stylesheet.css"> </head> <body> <div style="width: 95%; margin-left: auto; margin-right: auto;"> <!-- header //--> <?php require(DIR_WS_INCLUDES . 'header.php'); ?> <!-- header_eof //--> <!-- body //--> <table style="border: 3px; width: 100%; padding: 3px;"> <tr> <td style="width: <?php echo BOX_WIDTH; ?>; vertical-align: top;"><table style="border: 0; width: <?php echo BOX_WIDTH; ?>; padding: 2px;"> <!-- left_navigation //--> <?php require(DIR_WS_INCLUDES . 'column_left.php'); ?> <!-- left_navigation_eof //--> </table></td> <!-- body_text //--> <td style="width: 100%; vertical-align: top;"><table style="border: 0; width: 100%; padding: 0;"> <tr> <td><table style="border: 0; width: 100%; padding: 0;"> <tr> <td class="pageHeading"><?php echo HEADING_TITLE; ?></td> <td class="pageHeading" style="text-align: right;"><?php echo tep_image(DIR_WS_IMAGES . 'table_background_products_new.gif', HEADING_TITLE, HEADING_IMAGE_WIDTH, HEADING_IMAGE_HEIGHT); ?></td> </tr> </table></td> </tr> <tr> <td><?php echo tep_draw_separator('pixel_trans.gif', '100%', '10'); ?></td> </tr> <?php $products_new_array = array(); $products_new_query_raw = "select p.products_id, pd.products_name, p.products_image, p.products_price, p.products_tax_class_id, p.products_date_added, m.manufacturers_name from " . TABLE_PRODUCTS . " p left join " . TABLE_MANUFACTURERS . " m on (p.manufacturers_id = m.manufacturers_id), " . TABLE_PRODUCTS_DESCRIPTION . " pd where p.products_status = '1' and p.products_id = pd.products_id and pd.language_id = '" . (int)$languages_id . "' order by p.products_date_added DESC, pd.products_name"; $products_new_split = new splitPageResults($products_new_query_raw, MAX_DISPLAY_PRODUCTS_NEW); if (($products_new_split->number_of_rows > 0) && ((PREV_NEXT_BAR_LOCATION == '1') || (PREV_NEXT_BAR_LOCATION == '3'))) { ?> <tr> <td><table style="border: 0; width: 100%; padding: 2px;"> <tr> <td class="smallText"><?php echo $products_new_split->display_count(TEXT_DISPLAY_NUMBER_OF_PRODUCTS_NEW); ?></td> <td style="text-align: right;" class="smallText"><?php echo TEXT_RESULT_PAGE . ' ' . $products_new_split->display_links(MAX_DISPLAY_PAGE_LINKS, tep_get_all_get_params(array('page', 'info', 'x', 'y'))); ?></td> </tr> </table></td> </tr> <tr> <td><?php echo tep_draw_separator('pixel_trans.gif', '100%', '10'); ?></td> </tr> <?php } ?> <tr> <td><table style="border: 0; width: 100%; padding: 2px;"> <?php if ($products_new_split->number_of_rows > 0) { $products_new_query = tep_db_query($products_new_split->sql_query); while ($products_new = tep_db_fetch_array($products_new_query)) { if ($new_price = tep_get_products_special_price($products_new['products_id'])) { $products_price = '<s>' . $currencies->display_price($products_new['products_price'], tep_get_tax_rate($products_new['products_tax_class_id'])) . '</s><span class="productSpecialPrice">' . $currencies->display_price($new_price, tep_get_tax_rate($products_new['products_tax_class_id'])) . '</span>'; } else { $products_price = $currencies->display_price($products_new['products_price'], tep_get_tax_rate($products_new['products_tax_class_id'])); } ?> <tr> <td style="width: <?php echo SMALL_IMAGE_WIDTH + 10; ?>; vertical-align: top;" class="main"><?php echo '<a href="' . tep_href_link(FILENAME_PRODUCT_INFO, 'products_id=' . $products_new['products_id']) . '">' . tep_image(DIR_WS_IMAGES . $products_new['products_image'], $products_new['products_name'], SMALL_IMAGE_WIDTH, SMALL_IMAGE_HEIGHT) . '</a>'; ?></td> <td style="vertical-align: top;" class="main"><?php echo '<a href="' . tep_href_link(FILENAME_PRODUCT_INFO, 'products_id=' . $products_new['products_id']) . '"><b><u>' . $products_new['products_name'] . '</u></b></a><br>' . TEXT_DATE_ADDED . ' ' . tep_date_long($products_new['products_date_added']) . '<br>' . TEXT_MANUFACTURER . ' ' . $products_new['manufacturers_name'] . '<br><br>' . TEXT_PRICE . ' ' . $products_price; ?></td> <td style="text-align: right; vertical-align: middle;" class="main"><?php echo '<a href="' . tep_href_link(FILENAME_PRODUCTS_NEW, tep_get_all_get_params(array('action')) . 'action=buy_now&products_id=' . $products_new['products_id']) . '">' . tep_image_button('button_in_cart.gif', IMAGE_BUTTON_IN_CART) . '</a>'; ?></td> </tr> <tr> <td colspan="3"><?php echo tep_draw_separator('pixel_trans.gif', '100%', '10'); ?></td> </tr> <?php } } else { ?> <tr> <td class="main"><?php echo TEXT_NO_NEW_PRODUCTS; ?></td> </tr> <tr> <td><?php echo tep_draw_separator('pixel_trans.gif', '100%', '10'); ?></td> </tr> <?php } ?> </table></td> </tr> <?php if (($products_new_split->number_of_rows > 0) && ((PREV_NEXT_BAR_LOCATION == '2') || (PREV_NEXT_BAR_LOCATION == '3'))) { ?> <tr> <td><table style="border: 0; width: 100%; padding: 2px;"> <tr> <td class="smallText"><?php echo $products_new_split->display_count(TEXT_DISPLAY_NUMBER_OF_PRODUCTS_NEW); ?></td> <td style="text-align: right;" class="smallText"><?php echo TEXT_RESULT_PAGE . ' ' . $products_new_split->display_links(MAX_DISPLAY_PAGE_LINKS, tep_get_all_get_params(array('page', 'info', 'x', 'y'))); ?></td> </tr> </table></td> </tr> <?php } ?> </table></td> <!-- body_text_eof //--> <td style="width: <?php echo BOX_WIDTH; ?>; vertical-align: top;"><table style="border: 0; width: <?php echo BOX_WIDTH; ?>; padding: 2px;"> <!-- right_navigation //--> <?php require(DIR_WS_INCLUDES . 'column_right.php'); ?> <!-- right_navigation_eof //--> </table></td> </tr> </table> <!-- body_eof //--> <!-- footer //--> <?php require(DIR_WS_INCLUDES . 'footer.php'); ?> <!-- footer_eof //--> <br> </div> </body> </html> <?php require(DIR_WS_INCLUDES . 'application_bottom.php'); ?> I can't find any. Maybe a different set of eyes can spot the problem. You'll notice I've added a <div> to center the page as well as changing the code on the tables, rows, and data. I have used the same procedure on every other page. My noobness is showing by posting all of this page here, I'm sorry. I just don't know what else to try and maybe I'm being daft and can't see whatever is causing the problem. I appreciate your help but do not mean to bother. With plenty of contrition, B
Recommended Posts
Archived
This topic is now archived and is closed to further replies.