pnkranger Posted August 30, 2005 Share Posted August 30, 2005 Hi, Thank your for this great contrib, however I have a question. Is it not more logic to have the question of creat an account or not at the top of the page and not at the bottom? How could I move this to the top And the next question I have has not as much to do with this contrib but can you tell me how I could get the progress status bar to the top of the pages also instant of the bottom. Denice <{POST_SNAPBACK}> Nana, I installed your most recent version...a problem: I choose Purchase without account and finish a transaction. After clearing cace and cookies, etc., I try another purchase with the same e-mail address (choosing Purchase without account again) and it says...this e-mail already exists in our records... how is your new system supposed to work? also, you misspelled checkout_process.php in the submission. Quote Link to comment Share on other sites More sharing options...
jewelrytrends Posted August 30, 2005 Share Posted August 30, 2005 when I push checkout without placing anything in the cart I still get the creat account page, however it should show me the message your shopping cart is empty. Is this an error on my side, and how can I fix this? Quote Link to comment Share on other sites More sharing options...
Guest Posted August 30, 2005 Share Posted August 30, 2005 this is not a bug you have to unregister the cc information in checkout_confirmation.php on top of the file you see how i did this for cc and authorizenet and if you uncomment the print command you will see the list of the keys in the session you have to write a few lines like the ones for cc_number with variables from your module and this will resolve the issue <{POST_SNAPBACK}> Thanks very much for the assist Nana and that did the trick. I noticed in your comments in "catalog/checkout_confirmation.php" that you wanted to add unregister for other modules so here's what I did for the TrustCommerce module if that will help out. After this line... tep_session_unregister('authorizenet_cc_owner'); Add these lines... tep_session_unregister('trustcommerce_cc_number'); tep_session_unregister('trustcommerce_cc_cvv'); tep_session_unregister('trustcommerce_cc_expires_month'); tep_session_unregister('trustcommerce_cc_expires_year'); tep_session_unregister('trustcommerce_cc_owner'); Thanks again for the hard work and quick resonse! Quote Link to comment Share on other sites More sharing options...
pnkranger Posted August 30, 2005 Share Posted August 30, 2005 nana, thanks for all your hard work so far...did you ever get a chance to look at putting the newsletter Option on the checkout_success page... I think this is a good idea...tried it but couldn't get it to work properly. Quote Link to comment Share on other sites More sharing options...
nana Posted August 30, 2005 Author Share Posted August 30, 2005 triden thank you for posting the info pnkranger post what you did so maybe i can figure it out i and it should let you rgister i will take a look at the create_avvount.php and will let you know in a little while jewlerytrends add if ($cart->count_contents() < 1) { tep_redirect(tep_href_link(FILENAME_SHOPPING_CART)); } after require('includes/application_top.php'); that should do it but why would someone click checkout before making selection?!! the reason for the account being at the end is that i wanted it to be less intimidating and look as an after thought which i think it should be to move it up you just have to move the whole password block up i will look at it after i figured out the issue with login sorry for the misspelling folks i am not very good at it :blush: Quote Link to comment Share on other sites More sharing options...
nana Posted August 30, 2005 Author Share Posted August 30, 2005 please use this for create_account.php it should resolves most issues <?php /* $Id: create_account.php,v 1.65 2003/06/09 23:03:54 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'); if ($cart->count_contents() < 1) { tep_redirect(tep_href_link(FILENAME_SHOPPING_CART)); } if (tep_session_is_registered('customer_id')) { tep_redirect(tep_href_link(FILENAME_DEFAULT, '', 'SSL')); } // needs to be included earlier to set the success message in the messageStack require(DIR_WS_LANGUAGES . $language . '/' . FILENAME_CREATE_ACCOUNT); $process = false; if (isset($HTTP_POST_VARS['action']) && ($HTTP_POST_VARS['action'] == 'process')) { $process = true; $createaccount = tep_db_prepare_input($HTTP_POST_VARS['createaccount']); if($createaccount=='') $createaccount='Y'; if (ACCOUNT_GENDER == 'true') { if (isset($HTTP_POST_VARS['gender'])) { $gender = tep_db_prepare_input($HTTP_POST_VARS['gender']); } else { $gender = false; } } $firstname = tep_db_prepare_input($HTTP_POST_VARS['firstname']); $lastname = tep_db_prepare_input($HTTP_POST_VARS['lastname']); if (ACCOUNT_DOB == 'true') $dob = tep_db_prepare_input($HTTP_POST_VARS['dob']); $email_address = tep_db_prepare_input($HTTP_POST_VARS['email_address']); if (ACCOUNT_COMPANY == 'true') $company = tep_db_prepare_input($HTTP_POST_VARS['company']); $street_address = tep_db_prepare_input($HTTP_POST_VARS['street_address']); if (ACCOUNT_SUBURB == 'true') $suburb = tep_db_prepare_input($HTTP_POST_VARS['suburb']); $postcode = tep_db_prepare_input($HTTP_POST_VARS['postcode']); $city = tep_db_prepare_input($HTTP_POST_VARS['city']); if (ACCOUNT_STATE == 'true') { $state = tep_db_prepare_input($HTTP_POST_VARS['state']); if (isset($HTTP_POST_VARS['zone_id'])) { $zone_id = tep_db_prepare_input($HTTP_POST_VARS['zone_id']); } else { $zone_id = false; } } $country = tep_db_prepare_input($HTTP_POST_VARS['country']); $telephone = tep_db_prepare_input($HTTP_POST_VARS['telephone']); $fax = tep_db_prepare_input($HTTP_POST_VARS['fax']); if (isset($HTTP_POST_VARS['newsletter'])) { $newsletter = tep_db_prepare_input($HTTP_POST_VARS['newsletter']); } else { $newsletter = false; } $password = tep_db_prepare_input($HTTP_POST_VARS['password']); $confirmation = tep_db_prepare_input($HTTP_POST_VARS['confirmation']); if($password==''){ $password='calamazoo'; $confirmation='calamazoo';} $error = false; if (ACCOUNT_GENDER == 'true') { if ( ($gender != 'm') && ($gender != 'f') ) { $error = true; $messageStack->add('create_account', ENTRY_GENDER_ERROR); } } if (strlen($firstname) < ENTRY_FIRST_NAME_MIN_LENGTH) { $error = true; $messageStack->add('create_account', ENTRY_FIRST_NAME_ERROR); } if (strlen($lastname) < ENTRY_LAST_NAME_MIN_LENGTH) { $error = true; $messageStack->add('create_account', ENTRY_LAST_NAME_ERROR); } if (ACCOUNT_DOB == 'true') { if (checkdate(substr(tep_date_raw($dob), 4, 2), substr(tep_date_raw($dob), 6, 2), substr(tep_date_raw($dob), 0, 4)) == false) { $error = true; $messageStack->add('create_account', ENTRY_DATE_OF_BIRTH_ERROR); } } if (strlen($email_address) < ENTRY_EMAIL_ADDRESS_MIN_LENGTH) { $error = true; $messageStack->add('create_account', ENTRY_EMAIL_ADDRESS_ERROR); } elseif (tep_validate_email($email_address) == false) { $error = true; $messageStack->add('create_account', ENTRY_EMAIL_ADDRESS_CHECK_ERROR); } else { $check_email_query = tep_db_query("select count(*) as total from " . TABLE_CUSTOMERS . " where customers_email_address = '" . tep_db_input($email_address) . "'"); $check_email = tep_db_fetch_array($check_email_query); /* if ($check_email['total'] > 0) { $error = true; $messageStack->add('create_account', ENTRY_EMAIL_ADDRESS_ERROR_EXISTS); }*/ if ($check_email['total'] > 0) { //PWA delete account $get_customer_info = tep_db_query("select customers_id, customers_email_address, createaccount from " . TABLE_CUSTOMERS . " where customers_email_address = '" . tep_db_input($email_address) . "'"); $customer_info = tep_db_fetch_array($get_customer_info); $customer_id = $customer_info['customers_id']; $customer_email_address = $customer_info['customers_email_address']; $customer_pwa = $customer_info['createaccoun']; if ($customer_pwa =='N') { $error = true; $messageStack->add('create_account', ENTRY_EMAIL_ADDRESS_ERROR_EXISTS); } else { tep_db_query("delete from " . TABLE_ADDRESS_BOOK . " where customers_id = '" . $customer_id . "'"); tep_db_query("delete from " . TABLE_CUSTOMERS . " where customers_id = '" . $customer_id . "'"); tep_db_query("delete from " . TABLE_CUSTOMERS_INFO . " where customers_info_id = '" . $customer_id . "'"); tep_db_query("delete from " . TABLE_CUSTOMERS_BASKET . " where customers_id = '" . $customer_id . "'"); tep_db_query("delete from " . TABLE_CUSTOMERS_BASKET_ATTRIBUTES . " where customers_id = '" . $customer_id . "'"); tep_db_query("delete from " . TABLE_WHOS_ONLINE . " where customer_id = '" . $customer_id . "'"); } } // END } if (strlen($street_address) < ENTRY_STREET_ADDRESS_MIN_LENGTH) { $error = true; $messageStack->add('create_account', ENTRY_STREET_ADDRESS_ERROR); } if (strlen($postcode) < ENTRY_POSTCODE_MIN_LENGTH) { $error = true; $messageStack->add('create_account', ENTRY_POST_CODE_ERROR); } if (strlen($city) < ENTRY_CITY_MIN_LENGTH) { $error = true; $messageStack->add('create_account', ENTRY_CITY_ERROR); } if (is_numeric($country) == false) { $error = true; $messageStack->add('create_account', ENTRY_COUNTRY_ERROR); } if (ACCOUNT_STATE == 'true') { $zone_id = 0; $check_query = tep_db_query("select count(*) as total from " . TABLE_ZONES . " where zone_country_id = '" . (int)$country . "'"); $check = tep_db_fetch_array($check_query); $entry_state_has_zones = ($check['total'] > 0); if ($entry_state_has_zones == true) { $zone_query = tep_db_query("select distinct zone_id from " . TABLE_ZONES . " where zone_country_id = '" . (int)$country . "' and (zone_name like '" . tep_db_input($state) . "%' or zone_code like '%" . tep_db_input($state) . "%')"); if (tep_db_num_rows($zone_query) == 1) { $zone = tep_db_fetch_array($zone_query); $zone_id = $zone['zone_id']; } else { $error = true; $messageStack->add('create_account', ENTRY_STATE_ERROR_SELECT); } } else { if (strlen($state) < ENTRY_STATE_MIN_LENGTH) { $error = true; $messageStack->add('create_account', ENTRY_STATE_ERROR); } } } if (strlen($telephone) < ENTRY_TELEPHONE_MIN_LENGTH) { $error = true; $messageStack->add('create_account', ENTRY_TELEPHONE_NUMBER_ERROR); } if ($createaccount == 'Y') { if (strlen($password) < ENTRY_PASSWORD_MIN_LENGTH) { $error = true; $messageStack->add('create_account', ENTRY_PASSWORD_ERROR); } elseif ($password != $confirmation) { $error = true; $messageStack->add('create_account', ENTRY_PASSWORD_ERROR_NOT_MATCHING); } } if ($error == false) { $sql_data_array = array('customers_firstname' => $firstname, 'customers_lastname' => $lastname, 'customers_email_address' => $email_address, 'customers_telephone' => $telephone, 'customers_fax' => $fax, 'customers_newsletter' => $newsletter, 'createaccount' => $createaccount, 'customers_password' => tep_encrypt_password($password)); if (ACCOUNT_GENDER == 'true') $sql_data_array['customers_gender'] = $gender; if (ACCOUNT_DOB == 'true') $sql_data_array['customers_dob'] = tep_date_raw($dob); tep_db_perform(TABLE_CUSTOMERS, $sql_data_array); $customer_id = tep_db_insert_id(); $sql_data_array = array('customers_id' => $customer_id, 'entry_firstname' => $firstname, 'entry_lastname' => $lastname, 'entry_street_address' => $street_address, 'entry_postcode' => $postcode, 'entry_city' => $city, 'entry_country_id' => $country); if (ACCOUNT_GENDER == 'true') $sql_data_array['entry_gender'] = $gender; if (ACCOUNT_COMPANY == 'true') $sql_data_array['entry_company'] = $company; if (ACCOUNT_SUBURB == 'true') $sql_data_array['entry_suburb'] = $suburb; if (ACCOUNT_STATE == 'true') { if ($zone_id > 0) { $sql_data_array['entry_zone_id'] = $zone_id; $sql_data_array['entry_state'] = ''; } else { $sql_data_array['entry_zone_id'] = '0'; $sql_data_array['entry_state'] = $state; } } tep_db_perform(TABLE_ADDRESS_BOOK, $sql_data_array); $address_id = tep_db_insert_id(); tep_db_query("update " . TABLE_CUSTOMERS . " set customers_default_address_id = '" . (int)$address_id . "' where customers_id = '" . (int)$customer_id . "'"); tep_db_query("insert into " . TABLE_CUSTOMERS_INFO . " (customers_info_id, customers_info_number_of_logons, customers_info_date_account_created) values ('" . (int)$customer_id . "', '0', now())"); if (SESSION_RECREATE == 'True') { tep_session_recreate(); } $customer_first_name = $firstname; $customer_default_address_id = $address_id; $customer_country_id = $country; $customer_zone_id = $zone_id; tep_session_register('customer_id'); tep_session_register('customer_first_name'); tep_session_register('customer_default_address_id'); tep_session_register('customer_country_id'); tep_session_register('customer_zone_id'); if ($createaccount == 'N') tep_session_register('createaccount'); // restore cart contents $cart->restore_contents(); // build the message content $name = $firstname . ' ' . $lastname; if (ACCOUNT_GENDER == 'true') { if ($gender == 'm') { $email_text = sprintf(EMAIL_GREET_MR, $lastname); } else { $email_text = sprintf(EMAIL_GREET_MS, $lastname); } } else { $email_text = sprintf(EMAIL_GREET_NONE, $firstname); } $email_text .= EMAIL_WELCOME . EMAIL_TEXT . EMAIL_CONTACT . EMAIL_WARNING; if ($createaccount == 'Y') tep_mail($name, $email_address, EMAIL_SUBJECT, $email_text, STORE_OWNER, STORE_OWNER_EMAIL_ADDRESS); if ($createaccount == 'Y') { tep_redirect(tep_href_link(FILENAME_CREATE_ACCOUNT_SUCCESS, '', 'SSL')); } else { tep_redirect(tep_href_link(FILENAME_CHECKOUT_SHIPPING, '', 'SSL')); } } } $breadcrumb->add(NAVBAR_TITLE, tep_href_link(FILENAME_CREATE_ACCOUNT, '', 'SSL')); ?> <!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=<?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="stylesheet.css"> <?php require('includes/form_check.js.php'); ?> </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 //--> <table border="0" width="100%" cellspacing="3" cellpadding="3"> <tr> <td width="<?php echo BOX_WIDTH; ?>" valign="top"><table border="0" width="<?php echo BOX_WIDTH; ?>" cellspacing="0" cellpadding="2"> <!-- left_navigation //--> <?php require(DIR_WS_INCLUDES . 'column_left.php'); ?> <!-- left_navigation_eof //--> </table></td> <!-- body_text //--> <td width="100%" valign="top"><table border="0" width="100%" cellspacing="0" cellpadding="0"> <tr> <td><table border="0" width="100%" cellspacing="0" cellpadding="0"> <tr> <td class="pageHeading"><?php echo HEADING_TITLE; ?></td> </tr> </table></td> </tr> <?php if($fromlogin!=1){ ?> <tr> <td height="18" class="headerNavigation"><?php echo LOGINBOX_EXSISTING_CUSTOMER ?></td> </tr> <tr> <td><?php $loginboxcontent = tep_draw_form('login', tep_href_link(FILENAME_LOGIN, 'action=process', 'SSL')) . '<table width="310" border="0" cellspacing="0" cellpadding="0"><tr><td colspan="3" class="smallText">' .'<tr><td class="smallText">' . tep_draw_separator('pixel_trans.gif', '2', '1') . LOGINBOX_EMAIL . '</td><td class="smallText" colspan="3">' . tep_draw_input_field('email_address', '', 'size="10" maxlength="100" style="width: ' . (BOX_WIDTH-30) . 'px"') .'</td></tr><tr><td class="smallText">' . tep_draw_separator('pixel_trans.gif', '2', '1') . LOGINBOX_PASSWORD . '</td><td class="smallText">' . tep_draw_password_field('password', '', 'size="10" maxlength="40" style="width: ' . (BOX_WIDTH-30) . 'px"') . '</td><td class="smallText">' . '</a></td></tr><tr><td class="smallText" colspan="3">' . tep_draw_separator('pixel_trans.gif', '5', '25') . tep_image_submit('button_login.gif', IMAGE_BUTTON_LOGIN) . '</form>' . tep_draw_separator('pixel_trans.gif', '5', '1') . LOGINBOX_TEXT_PASSWORD . '<a href="' . tep_href_link(FILENAME_PASSWORD_FORGOTTEN, '', 'SSL') . '">' . LOGINBOX_FORGOT_PASSWORD . '</a></td></tr></table><tr>' ; $info_box_contents = array(); $info_box_contents[] = array('align' => '', 'text' => $loginboxcontent); new infoBox($info_box_contents); ?></td> </tr> <?php } ?> <td width="100%" valign="top"><?php echo tep_draw_form('create_account', tep_href_link(FILENAME_CREATE_ACCOUNT, '', 'SSL'), 'post', 'onSubmit="return check_form(create_account);"') . tep_draw_hidden_field('action', 'process'); ?> <tr> <td class="smallText"></td> </tr> <tr> <td><?php echo tep_draw_separator('pixel_trans.gif', '100%', '10'); ?></td> </tr> <?php if ($messageStack->size('create_account') > 0) { ?> <tr> <td><?php echo $messageStack->output('create_account'); ?></td> </tr> <tr> <td><?php echo tep_draw_separator('pixel_trans.gif', '100%', '10'); ?></td> </tr> <?php } ?> <tr> <td><table border="0" width="100%" cellspacing="0" cellpadding="2"> <tr> <td height="18" class="headerNavigation"><?php echo LOGINBOX_NEW_CUSTOMER ?></td> <td class="headerNavigation" align="right"><?php echo FORM_REQUIRED_INFORMATION; ?></td> </tr> </table></td> </tr> <tr> <td><table border="0" width="100%" cellspacing="1" cellpadding="2" class="infoBox"> <tr class="infoBoxContents"> <td><table border="0" cellspacing="2" cellpadding="2"> <?php if (ACCOUNT_GENDER == 'true') { ?> <tr> <td class="main"><?php echo ENTRY_GENDER; ?></td> <td class="main"><?php echo tep_draw_radio_field('gender', 'm') . ' ' . MALE . ' ' . tep_draw_radio_field('gender', 'f') . ' ' . FEMALE . ' ' . (tep_not_null(ENTRY_GENDER_TEXT) ? '<span class="inputRequirement">' . ENTRY_GENDER_TEXT . '</span>': ''); ?></td> </tr> <?php } ?> <tr> <td class="main"><?php echo ENTRY_FIRST_NAME; ?></td> <td class="main"><?php echo tep_draw_input_field('firstname') . ' ' . (tep_not_null(ENTRY_FIRST_NAME_TEXT) ? '<span class="inputRequirement">' . ENTRY_FIRST_NAME_TEXT . '</span>': ''); ?></td> </tr> <tr> <td class="main"><?php echo ENTRY_LAST_NAME; ?></td> <td class="main"><?php echo tep_draw_input_field('lastname') . ' ' . (tep_not_null(ENTRY_LAST_NAME_TEXT) ? '<span class="inputRequirement">' . ENTRY_LAST_NAME_TEXT . '</span>': ''); ?></td> </tr> <?php if (ACCOUNT_DOB == 'true') { ?> <tr> <td class="main"><?php echo ENTRY_DATE_OF_BIRTH; ?></td> <td class="main"><?php echo tep_draw_input_field('dob') . ' ' . (tep_not_null(ENTRY_DATE_OF_BIRTH_TEXT) ? '<span class="inputRequirement">' . ENTRY_DATE_OF_BIRTH_TEXT . '</span>': ''); ?></td> </tr> <?php } ?> <tr> <td class="main"><?php echo ENTRY_EMAIL_ADDRESS; ?></td> <td class="main"><?php echo tep_draw_input_field('email_address') . ' ' . (tep_not_null(ENTRY_EMAIL_ADDRESS_TEXT) ? '<span class="inputRequirement">' . ENTRY_EMAIL_ADDRESS_TEXT . '</span>': ''); ?></td> </tr> </table></td> </tr> </table></td> </tr> <?php if (ACCOUNT_COMPANY == 'true') { ?> <tr> <td><?php echo tep_draw_separator('pixel_trans.gif', '100%', '10'); ?></td> </tr> <tr> <td class="main"><b><?php echo CATEGORY_COMPANY; ?></b></td> </tr> <tr> <td><table border="0" width="100%" cellspacing="1" cellpadding="2" class="infoBox"> <tr class="infoBoxContents"> <td><table border="0" cellspacing="2" cellpadding="2"> <tr> <td class="main"><?php echo ENTRY_COMPANY; ?></td> <td class="main"><?php echo tep_draw_input_field('company') . ' ' . (tep_not_null(ENTRY_COMPANY_TEXT) ? '<span class="inputRequirement">' . ENTRY_COMPANY_TEXT . '</span>': ''); ?></td> </tr> </table></td> </tr> </table></td> </tr> <?php } ?> <tr> <td><?php echo tep_draw_separator('pixel_trans.gif', '100%', '10'); ?></td> </tr> <tr> <td class="main"><b><?php echo CATEGORY_ADDRESS; ?></b></td> </tr> <tr> <td><table border="0" width="100%" cellspacing="1" cellpadding="2" class="infoBox"> <tr class="infoBoxContents"> <td><table border="0" cellspacing="2" cellpadding="2"> <tr> <td class="main"><?php echo ENTRY_STREET_ADDRESS; ?></td> <td class="main"><?php echo tep_draw_input_field('street_address') . ' ' . (tep_not_null(ENTRY_STREET_ADDRESS_TEXT) ? '<span class="inputRequirement">' . ENTRY_STREET_ADDRESS_TEXT . '</span>': ''); ?></td> </tr> <?php if (ACCOUNT_SUBURB == 'true') { ?> <tr> <td class="main"><?php echo ENTRY_SUBURB; ?></td> <td class="main"><?php echo tep_draw_input_field('suburb') . ' ' . (tep_not_null(ENTRY_SUBURB_TEXT) ? '<span class="inputRequirement">' . ENTRY_SUBURB_TEXT . '</span>': ''); ?></td> </tr> <?php } ?> <tr> <td class="main"><?php echo ENTRY_POST_CODE; ?></td> <td class="main"><?php echo tep_draw_input_field('postcode') . ' ' . (tep_not_null(ENTRY_POST_CODE_TEXT) ? '<span class="inputRequirement">' . ENTRY_POST_CODE_TEXT . '</span>': ''); ?></td> </tr> <tr> <td class="main"><?php echo ENTRY_CITY; ?></td> <td class="main"><?php echo tep_draw_input_field('city') . ' ' . (tep_not_null(ENTRY_CITY_TEXT) ? '<span class="inputRequirement">' . ENTRY_CITY_TEXT . '</span>': ''); ?></td> </tr> <?php if (ACCOUNT_STATE == 'true') { ?> <tr> <td class="main"><?php echo ENTRY_STATE; ?></td> <td class="main"> <?php if ($process == true) { if ($entry_state_has_zones == true) { $zones_array = array(); $zones_query = tep_db_query("select zone_name from " . TABLE_ZONES . " where zone_country_id = '" . (int)$country . "' order by zone_name"); while ($zones_values = tep_db_fetch_array($zones_query)) { $zones_array[] = array('id' => $zones_values['zone_name'], 'text' => $zones_values['zone_name']); } echo tep_draw_pull_down_menu('state', $zones_array); } else { echo tep_draw_input_field('state'); } } else { echo tep_draw_input_field('state'); } if (tep_not_null(ENTRY_STATE_TEXT)) echo ' <span class="inputRequirement">' . ENTRY_STATE_TEXT; ?> </td> </tr> <?php } ?> <tr> <td class="main"><?php echo ENTRY_COUNTRY; ?></td> <td class="main"><?php echo tep_get_country_list('country') . ' ' . (tep_not_null(ENTRY_COUNTRY_TEXT) ? '<span class="inputRequirement">' . ENTRY_COUNTRY_TEXT . '</span>': ''); ?></td> </tr> </table></td> </tr> </table></td> </tr> <tr> <td><?php echo tep_draw_separator('pixel_trans.gif', '100%', '10'); ?></td> </tr> <tr> <td class="main"><b><?php echo CATEGORY_CONTACT; ?></b></td> </tr> <tr> <td><table border="0" width="100%" cellspacing="1" cellpadding="2" class="infoBox"> <tr class="infoBoxContents"> <td><table border="0" cellspacing="2" cellpadding="2"> <tr> <td class="main"><?php echo ENTRY_TELEPHONE_NUMBER; ?></td> <td class="main"><?php echo tep_draw_input_field('telephone') . ' ' . (tep_not_null(ENTRY_TELEPHONE_NUMBER_TEXT) ? '<span class="inputRequirement">' . ENTRY_TELEPHONE_NUMBER_TEXT . '</span>': ''); ?></td> </tr> <tr> <td class="main"><?php echo ENTRY_FAX_NUMBER; ?></td> <td class="main"><?php echo tep_draw_input_field('fax') . ' ' . (tep_not_null(ENTRY_FAX_NUMBER_TEXT) ? '<span class="inputRequirement">' . ENTRY_FAX_NUMBER_TEXT . '</span>': ''); ?></td> </tr> </table></td> </tr> </table></td> </tr> <tr> <td><?php echo tep_draw_separator('pixel_trans.gif', '100%', '10'); ?></td> </tr> <tr> <td class="main"><b><?php echo CATEGORY_OPTIONS; ?></b></td> </tr> <tr> <td><table border="0" width="100%" cellspacing="1" cellpadding="2" class="infoBox"> <tr class="infoBoxContents"> <td><table border="0" cellspacing="2" cellpadding="2"> <tr> <td class="main"><?php echo ENTRY_NEWSLETTER; ?></td> <td class="main"><?php echo tep_draw_checkbox_field('newsletter', '1') . ' ' . (tep_not_null(ENTRY_NEWSLETTER_TEXT) ? '<span class="inputRequirement">' . ENTRY_NEWSLETTER_TEXT . '</span>': ''); ?></td> </tr> </table></td> </tr> </table></td> </tr> <tr> <td><?php echo tep_draw_separator('pixel_trans.gif', '100%', '10'); ?></td> </tr> <tr> <td class="main"><b><?php if($fromlogin!=1){echo CATEGORY_CREATE_ACCOUNT;}else{echo CATEGORY_PASSWORD;} ?></b></td> </tr> <tr> <td><table border="0" width="100%" cellspacing="1" cellpadding="2" class="infoBox"> <tr class="infoBoxContents"> <td><table border="0" cellspacing="2" cellpadding="2"> <?php if($fromlogin!=1){ ?> <tr> <td class="main"><?php echo ENTRY_CREATEACCOUNT; ?></td> </tr> <tr> <td class="main"><?php echo tep_draw_radio_field('createaccount', 'Y',$checked = true) . ' ' . YES_ACCOUNT . ' </td></tr><tr><td class="main">' . tep_draw_radio_field('createaccount', 'N') . ' ' . NO_ACCOUNT . ' ' . (tep_not_null(ENTRY_GENDER_TEXT) ? '<span class="inputRequirement">' . ENTRY_GENDER_TEXT . '</span>': ''); ?></td> </tr> <tr> <td class="main">Please choose a password if you want to create an account</td> </tr></table><table> <?php } ?> <tr> <td class="main"><?php echo ENTRY_PASSWORD; ?></td> <td class="main"><?php echo tep_draw_password_field('password') . ' ' . (tep_not_null(ENTRY_PASSWORD_TEXT) ? '<span class="inputRequirement">' . ENTRY_PASSWORD_TEXT . '</span>': ''); ?></td> </tr> <tr> <td class="main"><?php echo ENTRY_PASSWORD_CONFIRMATION; ?></td> <td class="main"><?php echo tep_draw_password_field('confirmation') . ' ' . (tep_not_null(ENTRY_PASSWORD_CONFIRMATION_TEXT) ? '<span class="inputRequirement">' . ENTRY_PASSWORD_CONFIRMATION_TEXT . '</span>': ''); ?></td> </tr> </table></td> </tr> </table></td> </tr> <tr> <td><?php echo tep_draw_separator('pixel_trans.gif', '100%', '10'); ?></td> </tr> <tr> <td><table border="0" width="100%" cellspacing="1" cellpadding="2" class="infoBox"> <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><?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> </table></form></td> <!-- body_text_eof //--> <td width="<?php echo BOX_WIDTH; ?>" valign="top"><table border="0" width="<?php echo BOX_WIDTH; ?>" cellspacing="0" cellpadding="2"> <!-- right_navigation //--> <?php include(DIR_WS_INCLUDES . 'column_right.php'); ?> <!-- right_navigation_eof //--> </table></td> </tr> </table> <!-- body_eof //--> <!-- footer //--> <?php include(DIR_WS_INCLUDES . 'footer.php'); ?> <!-- footer_eof //--> <br> </body> </html> <?php require(DIR_WS_INCLUDES . 'application_bottom.php'); ?> Quote Link to comment Share on other sites More sharing options...
Guest Posted August 30, 2005 Share Posted August 30, 2005 I tested it on your test shop http://seelily.com/ Looks very good. I discovered just one bug. If you forget to choose i payment method and click on continue. The paymentmethod will loop. You can choose a payment method 100 times, but if you forgeted to do it the first time it would just loop it self. You cant get out off the select a payment form. Test and you will see! Have a nice day! ps. This look realy, realy good!!!!!! Wonderful work! Quote Link to comment Share on other sites More sharing options...
nana Posted August 31, 2005 Author Share Posted August 31, 2005 (edited) i resolved this issue but i think maybe i should do a little more testing before i release the next version i just added a line tep_session_register('payment'); in the checkout_payment.php after include application top blah blah i think the payment+shipping combo is working correctly please continue testing and post your findings please use create_account.php that i posted here rather than the one in version1.4 Edited August 31, 2005 by nana Quote Link to comment Share on other sites More sharing options...
pnkranger Posted August 31, 2005 Share Posted August 31, 2005 i resolved this issue but i think maybe i should do a little more testing before i release the next version i just added a line tep_session_register('payment'); in the checkout_payment.php after include application top blah blah i think the payment+shipping combo is working correctly please continue testing and post your findings please use create_account.php that i posted here rather than the one in version1.4 <{POST_SNAPBACK}> Can you tell me how this new "No Account" System is supposed to work so I can make sure it is operable? Thanks, Nick Quote Link to comment Share on other sites More sharing options...
pnkranger Posted August 31, 2005 Share Posted August 31, 2005 Nevermind...I got it all to work. I like this version very much. I tried to add a newsletter checkbox on the checkout_success.php page, but I am a rookie at this. Anybody have a fix for me? I can ge the correct checkbox on the page in the spot I want...I even registered the newsletter in the session so it would pop up only if the account does not currently receive the newsletter....couldn't make it post to the database though... What should I put in the php section of the checkout_success file and how should the <form> tag look to include both the notifications and the newsletter? Quote Link to comment Share on other sites More sharing options...
majestique Posted September 1, 2005 Share Posted September 1, 2005 (edited) I think the instructions for installing this mod isn't very clear.. and here's why: A. "1- upload the 2 files to catalog folder or make the changes " or make the changes? 2 files? your zip has more than 2 files... you should provide line by line on what to change for existing files.... B. " 3-add to your /languages/english/create_account.php define('NAVBAR_TITLE', 'Your Details'); define('HEADING_TITLE', 'Your Details'); define('LOGINBOX_NEW_CUSTOMER', 'New Customer - Please Fill in Your Details'); define('LOGINBOX_EXISTING_CUSTOMER', ' Existing Customer'); define('CATEGORY_CREATE_ACCOUNT', 'Create an Account?'); define('YES_ACCOUNT', 'Yes please, create an account for me.'); define('NO_ACCOUNT', 'No thanks, this is a one-off purchase.'); " You should state to replace "NAVBAR_TITLE" & "HEADING_TITLE" because it already exists in the lang file.. also it's /INCLUDES/languages/english/create_account.php C. " 5-add to CHECKOUT_PROCESS after tep_mail function i have made changes in three parts of checkout_process.php mostly like pwa" what does this mean? I don't get it... Edited September 1, 2005 by majestique Quote Link to comment Share on other sites More sharing options...
Guest Posted September 2, 2005 Share Posted September 2, 2005 (edited) For some reason i have this error when an exsisting customer pays for something and goes to the confirmation page..... tep_redirect(tep_href_link(FILENAME_CHECKOUT_SHIPPING, '', 'SSL')); Warning: session_start(): Cannot send session cache limiter - headers already sent (output started at /home/chronix/public_html/shop/checkout_confirmation.php:1) in /home/chronix/public_html/shop/includes/functions/sessions.php on line 67 The error is seen at the top. what can i do to fix this please? Edited September 2, 2005 by chronix Quote Link to comment Share on other sites More sharing options...
nana Posted September 5, 2005 Author Share Posted September 5, 2005 i have decided to seperate the instruction for the two part of this contribution since there is alternative to the second part and some people might want to only use the first part only i hope i have done a better job at it than before and it is more clear :blush: part one-combination of checkout_shipping.php and checkout_payment.php this reduces one click in the checkout process :P part two is for the combination login ,create account and pwa in one page which will reduce a second click :P i am trying to alter two existing contributions to work together in part two http://www.oscommerce.com/community/contributions,355/ http://www.oscommerce.com/community/contributions,3178 and i also have used http://www.oscommerce.com/community/contributions,2197 thanks to developers of all three they deserve all credit also added a link in the email that allows the customer to register an account if he did not originaly created one idea by burt also there is a second method of registering all customers as guest and give them the option to create an account in email also idea by burt test at as burt suggested my original both seems to work correctly also chronix that might be caused by a blank at either the very beginning or very end of the page checkout_confirmation.php Quote Link to comment Share on other sites More sharing options...
MeAndMom Posted September 5, 2005 Share Posted September 5, 2005 is there a way to add 4 required fields to this file somewhere on the checkout page for every order? I need this mod badly. Quote Link to comment Share on other sites More sharing options...
per4manz Posted September 5, 2005 Share Posted September 5, 2005 For some reason i have this error when an exsisting customer pays for something and goes to the confirmation page..... tep_redirect(tep_href_link(FILENAME_CHECKOUT_SHIPPING, '', 'SSL')); Warning: session_start(): Cannot send session cache limiter - headers already sent (output started at /home/chronix/public_html/shop/checkout_confirmation.php:1) in /home/chronix/public_html/shop/includes/functions/sessions.php on line 67 The error is seen at the top. what can i do to fix this please? <{POST_SNAPBACK}> You have a space either preceding the opening php tag (the <?php at the very beginning of the file) or after the closing tag (the ?> at the end of the file). The "/home/chronix/public_html/shop/checkout_confirmation.php:1" tells you it's on line 1 of checkout_confirmation.php. So, it is most likely a space before the opening php tag. If you do not see a space before the opening tag, try a different editor. I am not sure what system you are on, but BBEdit on the Mac fails to show the spaces before or after the php tags. You will need to try something like HyperEdit. On the Windows side I have no clue what to use if you run into the problem I had. Quote Link to comment Share on other sites More sharing options...
mysexytoes Posted September 5, 2005 Share Posted September 5, 2005 On your test site I noticed that I can now enter my state (note my earlier post about not being able to enter a state, lol) but noticed that when I hit the continue button I get an error that asks me to select my state and when I look there is now a dropdown box for the state. Quite annoying when I know I entered the state. Can the dropdown that has the states be moved to the main page? I recalled a contrib that I believe you pick your country and the drop down will show the zones in the list for that country to pick from could this be incorporated? I did some digging and I think it is this one Country-State Selector. It seems to be quite expansive though so not sure if this would be appropriate but perhas some of the code to do the basic would work? I'm no php'er etc.... Quote Link to comment Share on other sites More sharing options...
nana Posted September 5, 2005 Author Share Posted September 5, 2005 hello wanda i looked at this contribution and i do not see any particular reason why it should not work all the files are the same except create account and catalog/includes/form_check.js.php in these files i do not think that i have changed anything in regard to state only the number of lines might have changed my changes should not create any conflict with his if you have chosen to use create_account3.php instead of my original one i do not think there is a conflict either but i am not 100% sure you just have to be more carefull since there is two instances of the state unfortunatly i do not have much time to work on this for you just follow the direction carefully and you should be fine it is just some cut and paste and looking for the right code, if you read the code most of it is just plain english :thumbsup: Quote Link to comment Share on other sites More sharing options...
nana Posted September 6, 2005 Author Share Posted September 6, 2005 (edited) hello wanda i made the changes for the create_account only and it works you can try it out on my site and let me know if you need the file but you must make the other changes yourself i don't know if i like it or not Edited September 6, 2005 by nana Quote Link to comment Share on other sites More sharing options...
♥radders Posted September 7, 2005 Share Posted September 7, 2005 Hi Frank, I'm afraid I am rather stuck. I've made several attempts at installing this new version but I don't get very far. Where in my system should I look to find out what session variables need to be unregistered for Paypal Shopping Cart IPN and Worldpay? I can't seem to find the lines of code which do this (or even the ones that register the session in the first place. If this isn't done in the standard checkout, why does it need to be done in this version? Thanks David Quote Link to comment Share on other sites More sharing options...
mysexytoes Posted September 8, 2005 Share Posted September 8, 2005 Thanks for trying for me (it's all about the kids getting back to the school routine here so I can only get a few minutes here and there to look at code etc). Ok I tested it and I do not like how it is currently working as it will still throw a customer an error on the first time trying to enter their address. Ideally I feel it should work like this: Select Country from a drop down First Name Last Name Address City State (from dropdown dependent on the country picked above) zipcode phone etc. From an international perspective what do you call the state? Is it a region? territory? Quote Link to comment Share on other sites More sharing options...
nana Posted September 8, 2005 Author Share Posted September 8, 2005 hi david sorry i don't think i explained very good in the instruction i guess i have to fix that . Only payment modules that have a form on the site for cc# and so on have to unregister those variables so if there is a mistake they can fix it . nothing for paypal ipn and if you didn't need it for world pay you wouldn't need it now the only changes that i made to that part of the contribution is allowing for ccgv contribution let me know if you have any difficulties and sorry about this. all the other changes are regarding no account situations and ability to register multiple times with same email and offering to open an account in confirmation email and things like that hi wanda i don't like this either i was thinking of two solution regarding the state 1-disabling the error reporting. i do not see how anyone would make a mistake on the state they live in!!! i guess maybe only misspelling which i know a lot about :blush: 2-i came across a tip and trick tread from boxtel that can be used with the dropdown country/state thing to choose the correct country beforehand look at this Quote Link to comment Share on other sites More sharing options...
♥radders Posted September 8, 2005 Share Posted September 8, 2005 From an international perspective what do you call the state? Is it a region? territory? <{POST_SNAPBACK}> County, region, Province, State - depends on the country concerned Only payment modules that have a form on the site for cc# and so on have to unregister OK I understand. If you have to leave your site and enter the card information on the site belonging to the payment gateway, there is no need to unregister those items. The database changes. It mentions two changes but there is only one I can find. I presume that is just a mistake in the instructions. I don't have a compare program so I guess I'll just scan it though and see if I can spot any extra javscript functions. Thanks for that. I'll give it another go! Quote Link to comment Share on other sites More sharing options...
nana Posted September 8, 2005 Author Share Posted September 8, 2005 (edited) sorry again i did not need the second db change after all Edited September 8, 2005 by nana Quote Link to comment Share on other sites More sharing options...
nana Posted September 8, 2005 Author Share Posted September 8, 2005 for all people that are testing this if you complete a purchase without creating an account you will recive an invitation and a link to create an account since some of you are using nonexisting email accounts i wanted to point this out there are also two disting create_account pages located at http://seelily.com/create_account3.php and http://seelily.com/create_account.php one with no account creation at all and the other with optional account creation in both cases email includes the invitation i have not used any wording for this as of yet so you will see the constant Quote Link to comment Share on other sites More sharing options...
♥radders Posted September 9, 2005 Share Posted September 9, 2005 Not sure if I made an error in installing it but I found that I couldn't login in to an existing account. When I created a new account with the same email address it was accepted and the old account deleted. Should all the existing accounts in the database be changed when installing this along these lines? update customers set createaccount = 'Y' Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.