chrometweaks.org

Can I use a free web host then register a domain name from iPage?

Click Here To View All Answers...


Got a question, hope someone can answer... Can I use a free web host then register a domain name from iPage? Hoping for any comment. Another question I got... Hello!.

How can I change the create_account.php file. I dont want people to put in there gender at all, and I want some new things there to.. but when I try to get ried of gender the page want appear. it's just blank..

Is there someone that can help me with this??.

Regards Thomas..

Comments (138)

Ye, however you might want to make sure and wait for another commenter to confirm this as I am not quite sure. Better yet, why don't you give a call to the iPage guys because they can give you an answer better...

Comment #1

I have tried to delete from those files, but it didnt help me.. I only get a blank page if I try this.....

Comment #2

Well, the easiest way to get rid of the gender is to look in your Admin panel and go to configuration->customer_details and just set the display gender part to 'false'...

Comment #3

But it doesnt disappear whne people create a new acount.. and what if I want some more fields?.

Something like company and the registration number they have...

Comment #4

What version of OSC are you using as the Company field is part of MS2 as well as the gender field disappears if you disable it in Admin?..

Comment #5

I using the version 2.2.

Sorry my mistake..

I tried what you said and it worked, but what if I want som more fields then??.

I have tried to insert it to the create_account.php file but I cant get it to work...

Comment #6

I have added one called source.

You need to edit the following files:.

Create_account.php.

Create_account_process.php.

/includes/languages/english.php.

See docs files - and do a search on the documents for the word source and you will see where additional fields need to be added...

Comment #7

Create_account.php file.

<?php.

/*.

$Id: create_account.php,v 1.00 2003/07/24 23:03:54 Strider Exp $.

$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 © 2003 osCommerce.

Released under the GNU General Public License.

*/.

Require('includes/application_top.php');.

// 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;.

If (ACCOUNT_GENDER == 'true') {.

If (isset($HTTP_POST_VARS['gender'])) {.

$gender = tep_db_prepare_input($HTTP_POST_VARS['gender']);.

} else {.

$gender = false;.

}.

}.

$source = tep_db_prepare_input($HTTP_POST_VARS['source']); $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']);.

$source = tep_db_prepare_input($HTTP_POST_VARS['source']); $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']);.

$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 (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 (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('source' => $source, 'customers_firstname' => $firstname,.

'customers_lastname' => $lastname,.

'customers_email_address' => $email_address,.

'customers_telephone' => $telephone,.

'customers_fax' => $fax,.

'customers_newsletter' => $newsletter,.

'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');.

// 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_WELCOMEEMAIL_TEXTEMAIL_CONTACTEMAIL_WARNING;.

Tep_mail($name, $email_address, EMAIL_SUBJECT, $email_text, STORE_OWNER, STORE_OWNER_EMAIL_ADDRESS);.

Tep_redirect(tep_href_link(FILENAME_CREATE_ACCOUNT_SUCCESS, '', '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="Page-Enter" Content="blendtrans(duration=0.3)"></META> <meta http-equiv="Content-Type" content="text/html; charset=<?php echo CHARSET; ?>">.

<?php.

// BOF: WebMakers.com Changed: Header Tag Controller v1.0.

// Replaced by header_tags.php.

If ( file_exists(DIR_WS_INCLUDES'header_tags.php') ) {.

Require(DIR_WS_INCLUDES'header_tags.php');.

} else {.

?>.

<title><?php echo TITLE ?></title>.

<?php.

}.

// EOF: WebMakers.com Changed: Header Tag Controller v1.0.

?>.

<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="1" 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"><?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'); ?><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>.

<td class="pageHeading" align="right"><?php echo tep_image(DIR_WS_IMAGES'table_background_account.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>.

<tr>.

<td class="smallText"><br><?php echo sprintf(TEXT_ORIGIN_LOGIN, tep_href_link(FILENAME_LOGIN, tep_get_all_get_params(), 'SSL')); ?></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 class="main"><b><?php echo CATEGORY_PERSONAL; ?></b></td>.

<td class="inputRequirement" 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')'&nbsp;&nbsp;'MALE'&nbsp;&nbsp;'tep_draw_radio_field('gender', 'f')'&nbsp;&nbsp;'FEMALE'&nbsp;'(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')'&nbsp;'(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')'&nbsp;'(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')'&nbsp;'(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')'&nbsp;'(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')'&nbsp;'(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')'&nbsp;'(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')'&nbsp;'(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')'&nbsp;'(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')'&nbsp;'(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 '&nbsp;<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')'&nbsp;'(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')'&nbsp;'(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')'&nbsp;'(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', checked)'&nbsp;'(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 echo ENTRY_SOURCE; ?></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 'Where did you hear about yesUdo.com ?'; ?></td>.

<td class="main"><?php echo tep_draw_input_field('source')'&nbsp;'(tep_not_null(ENTRY_SOURCE_TEXT) ? '<span class="inputRequirement">'ENTRY_SOURCE_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_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">.

<tr>.

<td class="main"><?php echo ENTRY_PASSWORD; ?></td>.

<td class="main"><?php echo tep_draw_password_field('password')'&nbsp;'(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')'&nbsp;'(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="1" 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'); ?>..

Comment #8

Create_account_process.php.

<?php.

/*.

// deprecated as of 2.2ms2 Strider.

$Id: create_account_process.php,v 1.1.2.4 2003/05/02 22:23:01 wilt Exp $.

OsCommerce, Open Source E-Commerce Solutions.

Http://www.oscommerce.com.

Copyright © 2003 osCommerce.

Released under the GNU General Public License.

*/.

Require('includes/application_top.php');.

Require(DIR_WS_LANGUAGES$language'/'FILENAME_CREATE_ACCOUNT_PROCESS);.

If (!isset($HTTP_POST_VARS['action'])) {.

Tep_redirect(tep_href_link(FILENAME_CREATE_ACCOUNT));.

}.

$source = tep_db_prepare_input($HTTP_POST_VARS['source']);.

$gender = tep_db_prepare_input($HTTP_POST_VARS['gender']);.

$firstname = tep_db_prepare_input($HTTP_POST_VARS['firstname']);.

$lastname = tep_db_prepare_input($HTTP_POST_VARS['lastname']);.

$dob = tep_db_prepare_input($HTTP_POST_VARS['dob']);.

$email_address = tep_db_prepare_input($HTTP_POST_VARS['email_address']);.

$telephone = tep_db_prepare_input($HTTP_POST_VARS['telephone']);.

$fax = tep_db_prepare_input($HTTP_POST_VARS['fax']);.

$newsletter = tep_db_prepare_input($HTTP_POST_VARS['newsletter']);.

$password = tep_db_prepare_input($HTTP_POST_VARS['password']);.

$confirmation = tep_db_prepare_input($HTTP_POST_VARS['confirmation']);.

$street_address = tep_db_prepare_input($HTTP_POST_VARS['street_address']);.

$company = tep_db_prepare_input($HTTP_POST_VARS['company']);.

$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']);.

$zone_id = tep_db_prepare_input($HTTP_POST_VARS['zone_id']);.

$state = tep_db_prepare_input($HTTP_POST_VARS['state']);.

$country = tep_db_prepare_input($HTTP_POST_VARS['country']);.

$error = false; // reset error flag.

If (ACCOUNT_GENDER == 'true') {.

If (($gender == 'm') || ($gender == 'f')) {.

$entry_gender_error = false;.

} else {.

$error = true;.

$entry_gender_error = true;.

}.

}.

If (strlen($firstname) < ENTRY_FIRST_NAME_MIN_LENGTH) {.

$error = true;.

$entry_firstname_error = true;.

} else {.

$entry_firstname_error = false;.

}.

If (strlen($lastname) < ENTRY_LAST_NAME_MIN_LENGTH) {.

$error = true;.

$entry_lastname_error = true;.

} else {.

$entry_lastname_error = false;.

}.

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))) {.

$entry_date_of_birth_error = false;.

} else {.

$error = true;.

$entry_date_of_birth_error = true;.

}.

}.

If (strlen($email_address) < ENTRY_EMAIL_ADDRESS_MIN_LENGTH) {.

$error = true;.

$entry_email_address_error = true;.

} else {.

$entry_email_address_error = false;.

}.

If (!tep_validate_email($email_address)) {.

$error = true;.

$entry_email_address_check_error = true;.

} else {.

$entry_email_address_check_error = false;.

}.

If (strlen($street_address) < ENTRY_STREET_ADDRESS_MIN_LENGTH) {.

$error = true;.

$entry_street_address_error = true;.

} else {.

$entry_street_address_error = false;.

}.

If (strlen($postcode) < ENTRY_POSTCODE_MIN_LENGTH) {.

$error = true;.

$entry_post_code_error = true;.

} else {.

$entry_post_code_error = false;.

}.

If (strlen($city) < ENTRY_CITY_MIN_LENGTH) {.

$error = true;.

$entry_city_error = true;.

} else {.

$entry_city_error = false;.

}.

If (!$country) {.

$error = true;.

$entry_country_error = true;.

} else {.

$entry_country_error = false;.

}.

If (ACCOUNT_STATE == 'true') {.

If ($entry_country_error == true) {.

$entry_state_error = true;.

} else {.

$zone_id = 0;.

$entry_state_error = false;.

$check_query = tep_db_query("select count(*) as total from "TABLE_ZONES" where zone_country_id = '"tep_db_input($country)"'");.

$check_value = tep_db_fetch_array($check_query);.

$entry_state_has_zones = ($check_value['total'] > 0);.

If ($entry_state_has_zones == true) {.

$zone_query = tep_db_query("select zone_id from "TABLE_ZONES" where zone_country_id = '"tep_db_input($country)"' and zone_name = '"tep_db_input($state)"'");.

If (tep_db_num_rows($zone_query) == 1) {.

$zone_values = tep_db_fetch_array($zone_query);.

$zone_id = $zone_values['zone_id'];.

} else {.

$zone_query = tep_db_query("select zone_id from "TABLE_ZONES" where zone_country_id = '"tep_db_input($country)"' and zone_code = '"tep_db_input($state)"'");.

If (tep_db_num_rows($zone_query) == 1) {.

$zone_values = tep_db_fetch_array($zone_query);.

$zone_id = $zone_values['zone_id'];.

} else {.

$error = true;.

$entry_state_error = true;.

}.

}.

} else {.

If ($state == false) {.

$error = true;.

$entry_state_error = true;.

}.

}.

}.

}.

If (strlen($telephone) < ENTRY_TELEPHONE_MIN_LENGTH) {.

$error = true;.

$entry_telephone_error = true;.

} else {.

$entry_telephone_error = false;.

}.

$passlen = strlen($password);.

If ($passlen < ENTRY_PASSWORD_MIN_LENGTH) {.

$error = true;.

$entry_password_error = true;.

} else {.

$entry_password_error = false;.

}.

If ($password != $confirmation) {.

$error = true;.

$entry_password_error = true;.

}.

$check_email = tep_db_query("select customers_email_address from "TABLE_CUSTOMERS" where customers_email_address = '"tep_db_input($email_address)"' and customers_id <> '"tep_db_input($customer_id)"'");.

If (tep_db_num_rows($check_email)) {.

$error = true;.

$entry_email_address_exists = true;.

} else {.

$entry_email_address_exists = false;.

}.

If ($error == true) {.

$processed = true;.

$breadcrumb->add(NAVBAR_TITLE_1, tep_href_link(FILENAME_CREATE_ACCOUNT));.

$breadcrumb->add(NAVBAR_TITLE_2);.

?>.

<!doctype html public "-//W3C//DTD HTML 4.01 Transitional//EN">.

<html <?php echo HTML_PARAMS; ?>>.

<head>.

<META HTTP-EQUIV="Page-Enter" Content="blendtrans(duration=0.3)"></META>.

<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="1" 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"><?php echo tep_draw_form('account_edit', tep_href_link(FILENAME_CREATE_ACCOUNT_PROCESS, '', 'SSL'), 'post', 'onSubmit="return check_form();"')tep_draw_hidden_field('action', 'process'); ?><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>.

<td class="pageHeading" align="right"><?php echo tep_image(DIR_WS_IMAGES'table_background_account.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>.

<tr>.

<td><?php include(DIR_WS_MODULES'account_details.php'); ?></td>.

</tr>.

<tr>.

<td><?php echo tep_draw_separator('pixel_trans.gif', '100%', '10'); ?></td>.

</tr>.

<tr>.

<td><table border="0" width="100%" cellspacing="0" cellpadding="2">.

<tr>.

<td class="main" align="right"><?php echo tep_image_submit('button_continue.gif', IMAGE_BUTTON_CONTINUE); ?></td>.

</tr>.

</table></td>.

</tr>.

</table></form></td>.

<! body_text_eof //>.

<td width="<?php echo BOX_WIDTH; ?>" valign="top"><table border="1" 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.

} else {.

$sql_data_array = array('source' => $source,.

'customers_firstname' => $firstname,.

'customers_lastname' => $lastname,.

'customers_email_address' => $email_address,.

'customers_telephone' => $telephone,.

'customers_fax' => $fax,.

'customers_newsletter' => $newsletter,.

'customers_password' => tep_encrypt_password($password),.

'customers_default_address_id' => 1.

);.

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,.

'address_book_id' => 1,.

'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);.

Tep_db_query("insert into "TABLE_CUSTOMERS_INFO" (customers_info_id, customers_info_number_of_logons, customers_info_date_account_created) values ('"tep_db_input($customer_id)"', '0', now())");.

$customer_first_name = $firstname;.

$customer_default_address_id = 1;.

$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');.

// restore cart contents.

$cart->restore_contents();.

// build the message content.

$name = $firstname" "$lastname;.

If (ACCOUNT_GENDER == 'true') {.

If ($HTTP_POST_VARS['gender'] == 'm') {.

$email_text = EMAIL_GREET_MR;.

} else {.

$email_text = EMAIL_GREET_MS;.

}.

} else {.

$email_text = EMAIL_GREET_NONE;.

}.

$email_text .= EMAIL_WELCOME;.

Tep_redirect(tep_href_link(FILENAME_CREATE_ACCOUNT_SUCCESS, '', 'SSL'));.

}.

Require(DIR_WS_INCLUDES'application_bottom.php');.

?>..

Comment #9

/includes/languages/english.php file:.

<?php.

/*.

$Id: english.php,v 1.114 2003/07/09 18:13:39 dgw_ Exp $.

OsCommerce, Open Source E-Commerce Solutions.

Http://www.oscommerce.com.

Copyright © 2003 osCommerce.

Released under the GNU General Public License.

*/.

// look in your $PATH_LOCALE/locale directory for available locales.

// or type locale -a on the server..

// Examples:.

// on RedHat try 'en_US'.

// on FreeBSD try 'en_US.ISO_8859-1'.

// on Windows try 'en', or 'English'.

@setlocale(LC_TIME, 'en_US.ISO_8859-1');.

Define('DATE_FORMAT_SHORT', '%d/%m/%Y'); // this is used for strftime().

Define('DATE_FORMAT_LONG', '%A %d %B, %Y'); // this is used for strftime().

Define('DATE_FORMAT', 'd/m/Y'); // this is used for date().

Define('DATE_TIME_FORMAT', DATE_FORMAT_SHORT' %H:%M:%S');.

////.

// Return date in raw format.

// $date should be in format mm/dd/yyyy.

// raw date is in format YYYYMMDD, or DDMMYYYY.

Function tep_date_raw($date, $reverse = false) {.

If ($reverse) {.

Return substr($date, 6, 4)substr($date, 0, 2)substr($date, 3, 2);.

} else {.

Return substr($date, 6, 4)substr($date, 3, 2)substr($date, 0, 2);.

}.

}.

Function tep_date_raw1($date, $reverse = false) {.

If ($reverse) {.

Return substr($date, 3, 2)substr($date, 0, 2)substr($date, 6, 4);.

} else {.

Return substr($date, 6, 4)substr($date, 3, 2)substr($date, 0, 2);.

}.

}.

// if USE_DEFAULT_LANGUAGE_CURRENCY is true, use the following currency, instead of the applications default currency (used when changing language).

Define('LANGUAGE_CURRENCY', 'USD');.

// Global entries for the <html> tag.

Define('HTML_PARAMS','dir="LTR" lang="en"');.

// charset for web pages and emails.

Define('CHARSET', 'iso-8859-1');.

// page title.

Define('TITLE', 'yesUdo.com');.

// header text in includes/header.php.

Define('HEADER_TITLE_CREATE_ACCOUNT', 'Create an Account');.

Define('HEADER_TITLE_MY_ACCOUNT', 'Login');.

Define('HEADER_TITLE_CART_CONTENTS', 'Shopping Cart');.

Define('HEADER_TITLE_CHECKOUT', 'Checkout');.

Define('HEADER_TITLE_TOP', '<font color="ffff00">HOME</font>');.

Define('HEADER_TITLE_CATALOG', 'Catalog');.

Define('HEADER_TITLE_LOGOFF', 'Log Off');.

Define('HEADER_TITLE_LOGIN', 'Log In');.

// footer text in includes/footer.php.

Define('FOOTER_TEXT_REQUESTS_SINCE', 'requests since');.

// text for gender.

Define('MALE', 'Male');.

Define('FEMALE', 'Female');.

Define('MALE_ADDRESS', 'Mr.');.

Define('FEMALE_ADDRESS', 'Ms.');.

// text for date of birth example.

Define('DOB_FORMAT_STRING', 'dd/mm/yyyy');.

// categories box text in includes/boxes/categories.php.

Define('BOX_HEADING_CATEGORIES', '<center>Categories</center>');.

// manufacturers box text in includes/boxes/manufacturers.php.

Define('BOX_HEADING_MANUFACTURERS', 'Manufacturers');.

// whats_new box text in includes/boxes/whats_new.php.

Define('BOX_HEADING_WHATS_NEW', '<center>What\'s New?</center>');.

// quick_find box text in includes/boxes/quick_find.php.

Define('BOX_HEADING_SEARCH', '<center>Quick Find</center>');.

Define('BOX_SEARCH_TEXT', 'Use keywords to find the product you are looking for.');.

Define('BOX_SEARCH_ADVANCED_SEARCH', '<center>Advanced Search</center>');.

// specials box text in includes/boxes/specials.php.

Define('BOX_HEADING_SPECIALS_FOOTER', 'Current Offers');// specials box text in includes/boxes/specials.php.

Define('BOX_HEADING_SPECIALS', '<center>Current Offers</center>');.

// reviews box text in includes/boxes/reviews.php.

Define('BOX_HEADING_REVIEWS', '<center>Reviews</center>');.

Define('BOX_REVIEWS_WRITE_REVIEW', 'Write a review on this product!');.

Define('BOX_REVIEWS_NO_REVIEWS', 'There are currently no product reviews');.

Define('BOX_REVIEWS_TEXT_OF_5_STARS', '%s of 5 Stars!');.

// shopping_cart box text in includes/boxes/shopping_cart.php.

Define('BOX_HEADING_SHOPPING_CART', '<center>Shopping Cart</center>');.

Define('BOX_SHOPPING_CART_EMPTY', '0 items');.

// order_history box text in includes/boxes/order_history.php.

Define('BOX_HEADING_CUSTOMER_ORDERS', 'Order History');.

// best_sellers box text in includes/boxes/best_sellers.php.

Define('BOX_HEADING_BESTSELLERS', '<center>Bestsellers</center>');.

Define('BOX_HEADING_BESTSELLERS_IN', 'Bestsellers in<br>&nbsp;&nbsp;');.

// notifications box text in includes/boxes/products_notifications.php.

Define('BOX_HEADING_NOTIFICATIONS', '<center>Notifications</center>');.

Define('BOX_NOTIFICATIONS_NOTIFY', '<center>Notify me of updates to <b>%s</b></center>');.

Define('BOX_NOTIFICATIONS_NOTIFY_REMOVE', 'Do not notify me of updates to <b>%s</b>');.

// manufacturer box text.

Define('BOX_HEADING_MANUFACTURER_INFO', 'Manufacturer Info');.

Define('BOX_MANUFACTURER_INFO_HOMEPAGE', '%s Homepage');.

Define('BOX_MANUFACTURER_INFO_OTHER_PRODUCTS', 'Other products');.

// languages box text in includes/boxes/languages.php.

Define('BOX_HEADING_LANGUAGES', 'Languages');.

// currencies box text in includes/boxes/currencies.php.

Define('BOX_HEADING_CURRENCIES', '<center>Currencies</center>');.

// information box text in includes/boxes/information.php.

Define('BOX_HEADING_INFORMATION', '<font color="ff0000"><b><center>SITE INFORMATION<center></b></font>');.

Define('BOX_INFORMATION_PRIVACY', 'Privacy Notice');.

Define('BOX_INFORMATION_CONDITIONS', 'Conditions of Use');.

Define('BOX_INFORMATION_SHIPPING', 'Shipping & Returns');.

Define('BOX_INFORMATION_CONTACT', 'Contact Us');.

// tell a friend box text in includes/boxes/tell_a_friend.php.

Define('BOX_HEADING_TELL_A_FRIEND', '<center>Tell A Friend</center>');.

Define('BOX_TELL_A_FRIEND_TEXT', 'Tell someone you know about this product.');.

// checkout procedure text.

Define('CHECKOUT_BAR_DELIVERY', 'Delivery Information');.

Define('CHECKOUT_BAR_PAYMENT', 'Payment Information');.

Define('CHECKOUT_BAR_CONFIRMATION', 'Confirmation');.

Define('CHECKOUT_BAR_FINISHED', 'Finished!');.

// pull down default text.

Define('PULL_DOWN_DEFAULT', 'Please Select');.

Define('TYPE_BELOW', 'Type Below');.

// javascript messages.

Define('JS_ERROR', 'Errors have occured during the process of your form.\n\nPlease make the following corrections:\n\n');.

Define('JS_REVIEW_TEXT', '* The \'Review Text\' must have at least 'REVIEW_TEXT_MIN_LENGTH' characters.\n');.

Define('JS_REVIEW_RATING', '* You must rate the product for your review.\n');.

Define('JS_ERROR_NO_PAYMENT_MODULE_SELECTED', '* Please select a payment method for your order.\n');.

Define('JS_ERROR_SUBMITTED', 'This form has already been submitted. Please press Ok and wait for this process to be completed.');.

Define('ERROR_NO_PAYMENT_MODULE_SELECTED', 'Please select a payment method for your order.');.

Define('CATEGORY_COMPANY', 'Company Details');.

Define('CATEGORY_PERSONAL', 'Your Personal Details');.

Define('CATEGORY_ADDRESS', 'Your Address');.

Define('CATEGORY_CONTACT', 'Your Contact Information');.

Define('CATEGORY_OPTIONS', 'Options');.

Define('CATEGORY_PASSWORD', 'Your Password');.

Define('ENTRY_COMPANY', 'Company Name:');.

Define('ENTRY_COMPANY_ERROR', '');.

Define('ENTRY_COMPANY_TEXT', '');.

Define('ENTRY_GENDER', 'Gender:');.

Define('ENTRY_GENDER_ERROR', 'Please select your Gender.');.

Define('ENTRY_GENDER_TEXT', '*');.

Define('ENTRY_SOURCE', 'Please let us know:');define('ENTRY_FIRST_NAME', 'First Name:');.

Define('ENTRY_FIRST_NAME_ERROR', 'Your First Name must contain a minimum of 'ENTRY_FIRST_NAME_MIN_LENGTH' characters.');.

Define('ENTRY_FIRST_NAME_TEXT', '*');.

Define('ENTRY_LAST_NAME', 'Last Name:');.

Define('ENTRY_LAST_NAME_ERROR', 'Your Last Name must contain a minimum of 'ENTRY_LAST_NAME_MIN_LENGTH' characters.');.

Define('ENTRY_LAST_NAME_TEXT', '*');.

Define('ENTRY_DATE_OF_BIRTH', 'Date of Birth:');.

Define('ENTRY_DATE_OF_BIRTH_ERROR', 'Your Date of Birth must be in this format: DD/MM/YYYY (eg 21/07/1970)');.

Define('ENTRY_DATE_OF_BIRTH_TEXT', '* (eg. 21/07/1970)');.

Define('ENTRY_EMAIL_ADDRESS', 'E-Mail Address:');.

Define('ENTRY_EMAIL_ADDRESS_ERROR', 'Your E-Mail Address must contain a minimum of 'ENTRY_EMAIL_ADDRESS_MIN_LENGTH' characters.');.

Define('ENTRY_EMAIL_ADDRESS_CHECK_ERROR', 'Your E-Mail Address does not appear to be valid - please make any necessary corrections.');.

Define('ENTRY_EMAIL_ADDRESS_ERROR_EXISTS', 'Your E-Mail Address already exists in our records - please log in with the e-mail address or create an account with a different address.');.

Define('ENTRY_EMAIL_ADDRESS_TEXT', '*');.

Define('ENTRY_STREET_ADDRESS', 'Street Address:');.

Define('ENTRY_STREET_ADDRESS_ERROR', 'Your Street Address must contain a minimum of 'ENTRY_STREET_ADDRESS_MIN_LENGTH' characters.');.

Define('ENTRY_STREET_ADDRESS_TEXT', '*');.

Define('ENTRY_SUBURB', 'Suburb:');.

Define('ENTRY_SUBURB_ERROR', '');.

Define('ENTRY_SUBURB_TEXT', '');.

Define('ENTRY_POST_CODE', 'Post Code:');.

Define('ENTRY_POST_CODE_ERROR', 'Your Post Code must contain a minimum of 'ENTRY_POSTCODE_MIN_LENGTH' characters.');.

Define('ENTRY_POST_CODE_TEXT', '*');.

Define('ENTRY_CITY', 'City:');.

Define('ENTRY_CITY_ERROR', 'Your City must contain a minimum of 'ENTRY_CITY_MIN_LENGTH' characters.');.

Define('ENTRY_CITY_TEXT', '*');.

Define('ENTRY_STATE', 'County');.

Define('ENTRY_STATE_ERROR', 'Your county must contain a minimum of 'ENTRY_STATE_MIN_LENGTH' characters.');.

Define('ENTRY_STATE_ERROR_SELECT', 'Please select a state from the States pull down menu.');.

Define('ENTRY_STATE_TEXT', '*');.

Define('ENTRY_COUNTRY', 'Country:');.

Define('ENTRY_COUNTRY_ERROR', 'You must select a country from the Countries pull down menu.');.

Define('ENTRY_COUNTRY_TEXT', '*');.

Define('ENTRY_TELEPHONE_NUMBER', 'Telephone Number:');.

Define('ENTRY_TELEPHONE_NUMBER_ERROR', 'Your Telephone Number must contain a minimum of 'ENTRY_TELEPHONE_MIN_LENGTH' characters.');.

Define('ENTRY_TELEPHONE_NUMBER_TEXT', '*');.

Define('ENTRY_FAX_NUMBER', 'Fax Number:');.

Define('ENTRY_FAX_NUMBER_ERROR', '');.

Define('ENTRY_FAX_NUMBER_TEXT', '');define('ENTRY_SOURCE_TEXT', '');.

Define('ENTRY_NEWSLETTER', 'Newsletter:');.

Define('ENTRY_NEWSLETTER_TEXT', '');.

Define('ENTRY_NEWSLETTER_YES', 'Subscribed');.

Define('ENTRY_NEWSLETTER_NO', 'Unsubscribed');.

Define('ENTRY_NEWSLETTER_ERROR', '');.

Define('ENTRY_PASSWORD', 'Password:');.

Define('ENTRY_PASSWORD_ERROR', 'Your Password must contain a minimum of 'ENTRY_PASSWORD_MIN_LENGTH' characters.');.

Define('ENTRY_PASSWORD_ERROR_NOT_MATCHING', 'The Password Confirmation must match your Password.');.

Define('ENTRY_PASSWORD_TEXT', '*');.

Define('ENTRY_PASSWORD_CONFIRMATION', 'Password Confirmation:');.

Define('ENTRY_PASSWORD_CONFIRMATION_TEXT', '*');.

Define('ENTRY_PASSWORD_CURRENT', 'Current Password:');.

Define('ENTRY_PASSWORD_CURRENT_TEXT', '*');.

Define('ENTRY_PASSWORD_CURRENT_ERROR', 'Your Password must contain a minimum of 'ENTRY_PASSWORD_MIN_LENGTH' characters.');.

Define('ENTRY_PASSWORD_NEW', 'New Password:');.

Define('ENTRY_PASSWORD_NEW_TEXT', '*');.

Define('ENTRY_PASSWORD_NEW_ERROR', 'Your new Password must contain a minimum of 'ENTRY_PASSWORD_MIN_LENGTH' characters.');.

Define('ENTRY_PASSWORD_NEW_ERROR_NOT_MATCHING', 'The Password Confirmation must match your new Password.');.

Define('PASSWORD_HIDDEN', 'HIDDEN');.

Define('FORM_REQUIRED_INFORMATION', '* Required information');.

// constants for use in tep_prev_next_display function.

Define('TEXT_RESULT_PAGE', 'Result Pages:');.

Define('TEXT_DISPLAY_NUMBER_OF_PRODUCTS', 'Displaying <b>%d</b> to <b>%d</b> (of <b>%d</b> products)');.

Define('TEXT_DISPLAY_NUMBER_OF_ORDERS', 'Displaying <b>%d</b> to <b>%d</b> (of <b>%d</b> orders)');.

Define('TEXT_DISPLAY_NUMBER_OF_REVIEWS', 'Displaying <b>%d</b> to <b>%d</b> (of <b>%d</b> reviews)');.

Define('TEXT_DISPLAY_NUMBER_OF_PRODUCTS_NEW', 'Displaying <b>%d</b> to <b>%d</b> (of <b>%d</b> new products)');.

Define('TEXT_DISPLAY_NUMBER_OF_SPECIALS', 'Displaying <b>%d</b> to <b>%d</b> (of <b>%d</b> specials)');.

Define('PREVNEXT_TITLE_FIRST_PAGE', 'First Page');.

Define('PREVNEXT_TITLE_PREVIOUS_PAGE', 'Previous Page');.

Define('PREVNEXT_TITLE_NEXT_PAGE', 'Next Page');.

Define('PREVNEXT_TITLE_LAST_PAGE', 'Last Page');.

Define('PREVNEXT_TITLE_PAGE_NO', 'Page %d');.

Define('PREVNEXT_TITLE_PREV_SET_OF_NO_PAGE', 'Previous Set of %d Pages');.

Define('PREVNEXT_TITLE_NEXT_SET_OF_NO_PAGE', 'Next Set of %d Pages');.

Define('PREVNEXT_BUTTON_FIRST', '&lt;&lt;FIRST');.

Define('PREVNEXT_BUTTON_PREV', '[&lt;&lt;&nbsp;Prev]');.

Define('PREVNEXT_BUTTON_NEXT', '[Next&nbsp;&gt;&gt;]');.

Define('PREVNEXT_BUTTON_LAST', 'LAST&gt;&gt;');.

Define('IMAGE_BUTTON_ADD_ADDRESS', 'Add Address');.

Define('IMAGE_BUTTON_ADDRESS_BOOK', 'Address Book');.

Define('IMAGE_BUTTON_BACK', 'Back');.

Define('IMAGE_BUTTON_BUY_NOW', 'Buy Now');.

Define('IMAGE_BUTTON_CHANGE_ADDRESS', 'Change Address');.

Define('IMAGE_BUTTON_CHECKOUT', 'Checkout');.

Define('IMAGE_BUTTON_CONFIRM_ORDER', 'Confirm Order');.

Define('IMAGE_BUTTON_CONTINUE', 'Continue');.

Define('IMAGE_BUTTON_CONTINUE_SHOPPING', 'Continue Shopping');.

Define('IMAGE_BUTTON_DELETE', 'Delete');.

Define('IMAGE_BUTTON_EDIT_ACCOUNT', 'Edit Account');.

Define('IMAGE_BUTTON_HISTORY', 'Order History');.

Define('IMAGE_BUTTON_LOGIN', 'Sign In');.

Define('IMAGE_BUTTON_IN_CART', 'Add to Cart');.

Define('IMAGE_BUTTON_NOTIFICATIONS', 'Notifications');.

Define('IMAGE_BUTTON_QUICK_FIND', 'Quick Find');.

Define('IMAGE_BUTTON_REMOVE_NOTIFICATIONS', 'Remove Notifications');.

Define('IMAGE_BUTTON_REVIEWS', 'Reviews');.

Define('IMAGE_BUTTON_SEARCH', 'Search');.

Define('IMAGE_BUTTON_SHIPPING_OPTIONS', 'Shipping Options');.

Define('IMAGE_BUTTON_TELL_A_FRIEND', 'Tell a Friend');.

Define('IMAGE_BUTTON_UPDATE', 'Update');.

Define('IMAGE_BUTTON_UPDATE_CART', 'Update Cart');.

Define('IMAGE_BUTTON_WRITE_REVIEW', 'Write Review');.

Define('SMALL_IMAGE_BUTTON_DELETE', 'Delete');.

Define('SMALL_IMAGE_BUTTON_EDIT', 'Edit');.

Define('SMALL_IMAGE_BUTTON_VIEW', 'View');.

Define('ICON_ARROW_RIGHT', 'more');.

Define('ICON_CART', 'In Cart');.

Define('ICON_ERROR', 'Error');.

Define('ICON_SUCCESS', 'Success');.

Define('ICON_WARNING', 'Warning');.

Define('TEXT_GREETING_PERSONAL', 'Welcome back <span class="greetUser">%s!</span> Would you like to see which <a href="%s"><u>new products</u></a> are available to purchase?');.

Define('TEXT_GREETING_PERSONAL_RELOGON', '<small>If you are not %s, please <a href="%s"><u>log yourself in</u></a> with your account information.</small>');.

Define('TEXT_GREETING_GUEST', 'Welcome <span class="greetUser">Guest!</span> Would you like to <a href="%s"><u>log yourself in</u></a>? Or would you prefer to <a href="%s"><u>create an account</u></a>?');.

Define('TEXT_SORT_PRODUCTS', 'Sort products ');.

Define('TEXT_DESCENDINGLY', 'descendingly');.

Define('TEXT_ASCENDINGLY', 'ascendingly');.

Define('TEXT_BY', ' by ');.

Define('TEXT_REVIEW_BY', 'by %s');.

Define('TEXT_REVIEW_WORD_COUNT', '%s words');.

Define('TEXT_REVIEW_RATING', 'Rating: %s [%s]');.

Define('TEXT_REVIEW_DATE_ADDED', 'Date Added: %s');.

Define('TEXT_NO_REVIEWS', 'There are currently no product reviews.');.

Define('TEXT_NO_NEW_PRODUCTS', 'There are currently no products.');.

Define('TEXT_UNKNOWN_TAX_RATE', 'Unknown tax rate');.

Define('TEXT_REQUIRED', '<span class="errorText">Required</span>');.

Define('ERROR_TEP_MAIL', '<font face="Verdana, Arial" size="2" color="#ff0000"><b><small>TEP ERROR:</small> Cannot send the email through the specified SMTP server. Please check your php.ini setting and correct the SMTP server if necessary.</b></font>');.

Define('WARNING_INSTALL_DIRECTORY_EXISTS', 'Warning: Installation directory exists at: 'dirname($HTTP_SERVER_VARS['SCRIPT_FILENAME'])'/install. Please remove this directory for security reasons.');.

Define('WARNING_CONFIG_FILE_WRITEABLE', 'Warning: I am able to write to the configuration file: 'dirname($HTTP_SERVER_VARS['SCRIPT_FILENAME'])'/includes/configure.php. This is a potential security risk - please set the right user permissions on this file.');.

Define('WARNING_SESSION_DIRECTORY_NON_EXISTENT', 'Warning: The sessions directory does not exist: 'tep_session_save_path()'. Sessions will not work until this directory is created.');.

Define('WARNING_SESSION_DIRECTORY_NOT_WRITEABLE', 'Warning: I am not able to write to the sessions directory: 'tep_session_save_path()'. Sessions will not work until the right user permissions are set.');.

Define('WARNING_SESSION_AUTO_START', 'Warning: session.auto_start is enabled - please disable this php feature in php.ini and restart the web server.');.

Define('WARNING_DOWNLOAD_DIRECTORY_NON_EXISTENT', 'Warning: The downloadable products directory does not exist: 'DIR_FS_DOWNLOAD'. Downloadable products will not work until this directory is valid.');.

Define('TEXT_CCVAL_ERROR_INVALID_DATE', 'The expiry date entered for the credit card is invalid.<br>Please check the date and try again.');.

Define('TEXT_CCVAL_ERROR_INVALID_NUMBER', 'The credit card number entered is invalid.<br>Please check the number and try again.');.

Define('TEXT_CCVAL_ERROR_UNKNOWN_CARD', 'The first four digits of the number entered are: %s<br>If that number is correct, we do not accept that type of credit card.<br>If it is wrong, please try again.');.

/*.

The following copyright announcement can only be.

Appropriately modified or removed if the layout of.

The iPage site theme has been modified to distinguish.

Itself from the default osCommerce-copyrighted.

Theme..

For more information please read the following.

Frequently Asked Questions entry on the osCommerce.

Support site:.

Http://www.oscommerc...php/faq,26/q,50.

Please leave this comment intact together with the.

Following copyright announcement..

*/.

Define('FOOTER_TEXT_BODY', '<font size="1">Copyright &copy; 2003-2004 yesUdo.com - PO Box 155, Chessington, Surrey, KT9 1XR - Telephone: 0870 881 0339</font>'); require(DIR_WS_LANGUAGES'add_ccgvdc_english.php');.

Define('BOX_HEADING_SUBSCRIBERS', 'Subscribe');.

Define('BOX_TEXT_SUBSCRIBE', 'Subscribe');.

Define('BOX_TEXT_UNSUBSCRIBE', 'Un-Subscribe');.

Define('STOCK_EPUISE', '<font color="#FF0000"><b>CURRENTLY OUT OF STOCK</b></font>');.

Define('STOCK_LIMITE', '<font color="#FF6600"><b>LIMITED STOCK</b></font>');.

Define('STOCK_DISPO', '<font color = "#00CC00"><b>PRODUCT IN STOCK</b></font>');.

?>..

Comment #10

Just thought you need to amend admin/customers.php also - see below..

Comment #11

Admin/customers.php.

<?php.

/*.

$Id: customers.php,v 1.82 2003/06/30 13:54:14 dgw_ Exp $.

OsCommerce, Open Source E-Commerce Solutions.

Http://www.oscommerce.com.

Copyright © 2003 osCommerce.

Released under the GNU General Public License.

*/.

Require('includes/application_top.php');.

$action = (isset($HTTP_GET_VARS['action']) ? $HTTP_GET_VARS['action'] : '');.

$error = false;.

$processed = false;.

If (tep_not_null($action)) {.

Switch ($action) {.

Case 'update':.

$source = tep_db_prepare_input($HTTP_GET_VARS['source']);.

$customers_id = tep_db_prepare_input($HTTP_GET_VARS['cID']);.

$customers_firstname = tep_db_prepare_input($HTTP_POST_VARS['customers_firstname']);.

$customers_lastname = tep_db_prepare_input($HTTP_POST_VARS['customers_lastname']);.

$customers_email_address = tep_db_prepare_input($HTTP_POST_VARS['customers_email_address']);.

$customers_telephone = tep_db_prepare_input($HTTP_POST_VARS['customers_telephone']);.

$customers_fax = tep_db_prepare_input($HTTP_POST_VARS['customers_fax']);.

$customers_newsletter = tep_db_prepare_input($HTTP_POST_VARS['customers_newsletter']);.

$customers_gender = tep_db_prepare_input($HTTP_POST_VARS['customers_gender']);.

$customers_dob = tep_db_prepare_input($HTTP_POST_VARS['customers_dob']);.

$default_address_id = tep_db_prepare_input($HTTP_POST_VARS['default_address_id']);.

$entry_street_address = tep_db_prepare_input($HTTP_POST_VARS['entry_street_address']);.

$entry_suburb = tep_db_prepare_input($HTTP_POST_VARS['entry_suburb']);.

$entry_postcode = tep_db_prepare_input($HTTP_POST_VARS['entry_postcode']);.

$entry_city = tep_db_prepare_input($HTTP_POST_VARS['entry_city']);.

$entry_country_id = tep_db_prepare_input($HTTP_POST_VARS['entry_country_id']);.

$entry_company = tep_db_prepare_input($HTTP_POST_VARS['entry_company']);.

$entry_state = tep_db_prepare_input($HTTP_POST_VARS['entry_state']);.

If (isset($HTTP_POST_VARS['entry_zone_id'])) $entry_zone_id = tep_db_prepare_input($HTTP_POST_VARS['entry_zone_id']);.

If (strlen($customers_firstname) < ENTRY_FIRST_NAME_MIN_LENGTH) {.

$error = true;.

$entry_firstname_error = true;.

} else {.

$entry_firstname_error = false;.

}.

If (strlen($customers_lastname) < ENTRY_LAST_NAME_MIN_LENGTH) {.

$error = true;.

$entry_lastname_error = true;.

} else {.

$entry_lastname_error = false;.

}.

If (ACCOUNT_DOB == 'true') {.

If (checkdate(substr(tep_date_raw($customers_dob), 4, 2), substr(tep_date_raw($customers_dob), 6, 2), substr(tep_date_raw($customers_dob), 0, 4))) {.

$entry_date_of_birth_error = false;.

} else {.

$error = true;.

$entry_date_of_birth_error = true;.

}.

}.

If (strlen($customers_email_address) < ENTRY_EMAIL_ADDRESS_MIN_LENGTH) {.

$error = true;.

$entry_email_address_error = true;.

} else {.

$entry_email_address_error = false;.

}.

If (!tep_validate_email($customers_email_address)) {.

$error = true;.

$entry_email_address_check_error = true;.

} else {.

$entry_email_address_check_error = false;.

}.

If (strlen($entry_street_address) < ENTRY_STREET_ADDRESS_MIN_LENGTH) {.

$error = true;.

$entry_street_address_error = true;.

} else {.

$entry_street_address_error = false;.

}.

If (strlen($entry_postcode) < ENTRY_POSTCODE_MIN_LENGTH) {.

$error = true;.

$entry_post_code_error = true;.

} else {.

$entry_post_code_error = false;.

}.

If (strlen($entry_city) < ENTRY_CITY_MIN_LENGTH) {.

$error = true;.

$entry_city_error = true;.

} else {.

$entry_city_error = false;.

}.

If ($entry_country_id == false) {.

$error = true;.

$entry_country_error = true;.

} else {.

$entry_country_error = false;.

}.

If (ACCOUNT_STATE == 'true') {.

If ($entry_country_error == true) {.

$entry_state_error = true;.

} else {.

$zone_id = 0;.

$entry_state_error = false;.

$check_query = tep_db_query("select count(*) as total from "TABLE_ZONES" where zone_country_id = '"(int)$entry_country_id"'");.

$check_value = tep_db_fetch_array($check_query);.

$entry_state_has_zones = ($check_value['total'] > 0);.

If ($entry_state_has_zones == true) {.

$zone_query = tep_db_query("select zone_id from "TABLE_ZONES" where zone_country_id = '"(int)$entry_country_id"' and zone_name = '"tep_db_input($entry_state)"'");.

If (tep_db_num_rows($zone_query) == 1) {.

$zone_values = tep_db_fetch_array($zone_query);.

$entry_zone_id = $zone_values['zone_id'];.

} else {.

$error = true;.

$entry_state_error = true;.

}.

} else {.

If ($entry_state == false) {.

$error = true;.

$entry_state_error = true;.

}.

}.

}.

}.

If (strlen($customers_telephone) < ENTRY_TELEPHONE_MIN_LENGTH) {.

$error = true;.

$entry_telephone_error = true;.

} else {.

$entry_telephone_error = false;.

}.

$check_email = tep_db_query("select customers_email_address from "TABLE_CUSTOMERS" where customers_email_address = '"tep_db_input($customers_email_address)"' and customers_id != '"(int)$customers_id"'");.

If (tep_db_num_rows($check_email)) {.

$error = true;.

$entry_email_address_exists = true;.

} else {.

$entry_email_address_exists = false;.

}.

If ($error == false) {.

$sql_data_array = array('customers_firstname' => $customers_firstname,.

'customers_lastname' => $customers_lastname,.

'customers_email_address' => $customers_email_address,.

'customers_telephone' => $customers_telephone,.

'customers_fax' => $customers_fax,.

'customers_newsletter' => $customers_newsletter,.

'source' => $source);.

If (ACCOUNT_GENDER == 'true') $sql_data_array['customers_gender'] = $customers_gender;.

If (ACCOUNT_DOB == 'true') $sql_data_array['customers_dob'] = tep_date_raw($customers_dob);.

Tep_db_perform(TABLE_CUSTOMERS, $sql_data_array, 'update', "customers_id = '"(int)$customers_id"'");.

Tep_db_query("update "TABLE_CUSTOMERS_INFO" set customers_info_date_account_last_modified = now() where customers_info_id = '"(int)$customers_id"'");.

If ($entry_zone_id > 0) $entry_state = '';.

$sql_data_array = array('entry_firstname' => $customers_firstname,.

'entry_lastname' => $customers_lastname,.

'entry_street_address' => $entry_street_address,.

'entry_postcode' => $entry_postcode,.

'entry_city' => $entry_city,.

'entry_country_id' => $entry_country_id);.

If (ACCOUNT_COMPANY == 'true') $sql_data_array['entry_company'] = $entry_company;.

If (ACCOUNT_SUBURB == 'true') $sql_data_array['entry_suburb'] = $entry_suburb;.

If (ACCOUNT_STATE == 'true') {.

If ($entry_zone_id > 0) {.

$sql_data_array['entry_zone_id'] = $entry_zone_id;.

$sql_data_array['entry_state'] = '';.

} else {.

$sql_data_array['entry_zone_id'] = '0';.

$sql_data_array['entry_state'] = $entry_state;.

}.

}.

Tep_db_perform(TABLE_ADDRESS_BOOK, $sql_data_array, 'update', "customers_id = '"(int)$customers_id"' and address_book_id = '"(int)$default_address_id"'");.

Tep_redirect(tep_href_link(FILENAME_CUSTOMERS, tep_get_all_get_params(array('cID', 'action'))'cID='$customers_id));.

} else if ($error == true) {.

$cInfo = new objectInfo($HTTP_POST_VARS);.

$processed = true;.

}.

Break;.

Case 'deleteconfirm':.

$customers_id = tep_db_prepare_input($HTTP_GET_VARS['cID']);.

If (isset($HTTP_POST_VARS['delete_reviews']) && ($HTTP_POST_VARS['delete_reviews'] == 'on')) {.

$reviews_query = tep_db_query("select reviews_id from "TABLE_REVIEWS" where customers_id = '"(int)$customers_id"'");.

While ($reviews = tep_db_fetch_array($reviews_query)) {.

Tep_db_query("delete from "TABLE_REVIEWS_DESCRIPTION" where reviews_id = '"(int)$reviews['reviews_id']"'");.

}.

Tep_db_query("delete from "TABLE_REVIEWS" where customers_id = '"(int)$customers_id"'");.

} else {.

Tep_db_query("update "TABLE_REVIEWS" set customers_id = null where customers_id = '"(int)$customers_id"'");.

}.

Tep_db_query("delete from "TABLE_ADDRESS_BOOK" where customers_id = '"(int)$customers_id"'");.

Tep_db_query("delete from "TABLE_CUSTOMERS" where customers_id = '"(int)$customers_id"'");.

Tep_db_query("delete from "TABLE_CUSTOMERS_INFO" where customers_info_id = '"(int)$customers_id"'");.

Tep_db_query("delete from "TABLE_CUSTOMERS_BASKET" where customers_id = '"(int)$customers_id"'");.

Tep_db_query("delete from "TABLE_CUSTOMERS_BASKET_ATTRIBUTES" where customers_id = '"(int)$customers_id"'");.

Tep_db_query("delete from "TABLE_WHOS_ONLINE" where customer_id = '"(int)$customers_id"'");.

Tep_redirect(tep_href_link(FILENAME_CUSTOMERS, tep_get_all_get_params(array('cID', 'action'))));.

Break;.

Default:.

$customers_query = tep_db_query("select c.source, c.customers_id, c.customers_gender, c.customers_firstname, c.customers_lastname, c.customers_dob, c.customers_email_address, a.entry_company, a.entry_street_address, a.entry_suburb, a.entry_postcode, a.entry_city, a.entry_state, a.entry_zone_id, a.entry_country_id, c.customers_telephone, c.customers_fax, c.customers_newsletter, c.customers_default_address_id from "TABLE_CUSTOMERS" c left join "TABLE_ADDRESS_BOOK" a on c.customers_default_address_id = a.address_book_id where a.customers_id = c.customers_id and c.customers_id = '"(int)$HTTP_GET_VARS['cID']"'");.

$customers = tep_db_fetch_array($customers_query);.

$cInfo = new objectInfo($customers);.

}.

}.

?>.

<!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>.

<link rel="stylesheet" type="text/css" href="includes/stylesheet.css">.

<script language="javascript" src="includes/general.js"></script>.

<?php.

If ($action == 'edit' || $action == 'update') {.

?>.

<script language="javascript"><!.

Function check_form() {.

Var error = 0;.

Var error_message = "<?php echo JS_ERROR; ?>";.

Var customers_firstname = document.customers.customers_firstname.value;.

Var customers_lastname = document.customers.customers_lastname.value;.

<?php if (ACCOUNT_COMPANY == 'true') echo 'var entry_company = document.customers.entry_company.value;'"\n"; ?>.

<?php if (ACCOUNT_DOB == 'true') echo 'var customers_dob = document.customers.customers_dob.value;'"\n"; ?>.

Var customers_email_address = document.customers.customers_email_address.value;.

Var entry_street_address = document.customers.entry_street_address.value;.

Var entry_postcode = document.customers.entry_postcode.value;.

Var entry_city = document.customers.entry_city.value;.

Var customers_telephone = document.customers.customers_telephone.value;.

{}var source = document.customers.sourcecustomers_telephone.value;.

<?php if (ACCOUNT_GENDER == 'true') { ?>.

If (document.customers.customers_gender[0].checked || document.customers.customers_gender[1].checked) {.

} else {.

Error_message = error_message + "<?php echo JS_GENDER; ?>";.

Error = 1;.

}.

<?php } ?>.

If (customers_firstname == "" || customers_firstname.length < <?php echo ENTRY_FIRST_NAME_MIN_LENGTH; ?>) {.

Error_message = error_message + "<?php echo JS_FIRST_NAME; ?>";.

Error = 1;.

}.

If (customers_lastname == "" || customers_lastname.length < <?php echo ENTRY_LAST_NAME_MIN_LENGTH; ?>) {.

Error_message = error_message + "<?php echo JS_LAST_NAME; ?>";.

Error = 1;.

}.

<?php if (ACCOUNT_DOB == 'true') { ?>.

If (customers_dob == "" || customers_dob.length < <?php echo ENTRY_DOB_MIN_LENGTH; ?>) {.

Error_message = error_message + "<?php echo JS_DOB; ?>";.

Error = 1;.

}.

<?php } ?>.

If (customers_email_address == "" || customers_email_address.length < <?php echo ENTRY_EMAIL_ADDRESS_MIN_LENGTH; ?>) {.

Error_message = error_message + "<?php echo JS_EMAIL_ADDRESS; ?>";.

Error = 1;.

}.

If (entry_street_address == "" || entry_street_address.length < <?php echo ENTRY_STREET_ADDRESS_MIN_LENGTH; ?>) {.

Error_message = error_message + "<?php echo JS_ADDRESS; ?>";.

Error = 1;.

}.

If (entry_postcode == "" || entry_postcode.length < <?php echo ENTRY_POSTCODE_MIN_LENGTH; ?>) {.

Error_message = error_message + "<?php echo JS_POST_CODE; ?>";.

Error = 1;.

}.

If (entry_city == "" || entry_city.length < <?php echo ENTRY_CITY_MIN_LENGTH; ?>) {.

Error_message = error_message + "<?php echo JS_CITY; ?>";.

Error = 1;.

}.

<?php.

If (ACCOUNT_STATE == 'true') {.

?>.

If (document.customers.elements['entry_state'].type != "hidden") {.

If (document.customers.entry_state.value == '' || document.customers.entry_state.value.length < <?php echo ENTRY_STATE_MIN_LENGTH; ?> ) {.

Error_message = error_message + "<?php echo JS_STATE; ?>";.

Error = 1;.

}.

}.

<?php.

}.

?>.

If (document.customers.elements['entry_country_id'].type != "hidden") {.

If (document.customers.entry_country_id.value == 0) {.

Error_message = error_message + "<?php echo JS_COUNTRY; ?>";.

Error = 1;.

}.

}.

If (customers_telephone == "" || customers_telephone.length < <?php echo ENTRY_TELEPHONE_MIN_LENGTH; ?>) {.

Error_message = error_message + "<?php echo JS_TELEPHONE; ?>";.

Error = 1;.

}.

If (error == 1) {.

Alert(error_message);.

Return false;.

} else {.

Return true;.

}.

}.

//></script>.

<?php.

}.

?>.

</head>.

<body marginwidth="0" marginheight="0" topmargin="0" bottommargin="0" leftmargin="0" rightmargin="0" bgcolor="#FFFFFF" onload="SetFocus();">.

<! header //>.

<?php require(DIR_WS_INCLUDES'header.php'); ?>.

<! header_eof //>.

<! body //>.

<table border="0" width="100%" cellspacing="2" cellpadding="2">.

<tr>.

<td width="<?php echo BOX_WIDTH; ?>" valign="top"><table border="0" width="<?php echo BOX_WIDTH; ?>" cellspacing="1" cellpadding="1" class="columnLeft">.

<! 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="2">.

<?php.

If ($action == 'edit' || $action == 'update') {.

$newsletter_array = array(array('id' => '1', 'text' => ENTRY_NEWSLETTER_YES),.

Array('id' => '0', 'text' => ENTRY_NEWSLETTER_NO));.

?>.

<tr>.

<td><table border="0" width="100%" cellspacing="0" cellpadding="0">.

<tr>.

<td class="pageHeading"><?php echo HEADING_TITLE; ?></td>.

<td class="pageHeading" align="right"><?php echo tep_draw_separator('pixel_trans.gif', HEADING_IMAGE_WIDTH, HEADING_IMAGE_HEIGHT); ?></td>.

</tr>.

</table></td>.

</tr>.

<tr>.

<td><?php echo tep_draw_separator('pixel_trans.gif', '1', '10'); ?></td>.

</tr>.

<tr><?php echo tep_draw_form('customers', FILENAME_CUSTOMERS, tep_get_all_get_params(array('action'))'action=update', 'post', 'onSubmit="return check_form();"')tep_draw_hidden_field('default_address_id', $cInfo->customers_default_address_id); ?>.

<td class="formAreaTitle"><?php echo CATEGORY_PERSONAL; ?></td>.

</tr>.

<tr>.

<td class="formArea"><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.

If ($error == true) {.

If ($entry_gender_error == true) {.

Echo tep_draw_radio_field('customers_gender', 'm', false, $cInfo->customers_gender)'&nbsp;&nbsp;'MALE'&nbsp;&nbsp;'tep_draw_radio_field('customers_gender', 'f', false, $cInfo->customers_gender)'&nbsp;&nbsp;'FEMALE'&nbsp;'ENTRY_GENDER_ERROR;.

} else {.

Echo ($cInfo->customers_gender == 'm') ? MALE : FEMALE;.

Echo tep_draw_hidden_field('customers_gender');.

}.

} else {.

Echo tep_draw_radio_field('customers_gender', 'm', false, $cInfo->customers_gender)'&nbsp;&nbsp;'MALE'&nbsp;&nbsp;'tep_draw_radio_field('customers_gender', 'f', false, $cInfo->customers_gender)'&nbsp;&nbsp;'FEMALE;.

}.

?></td>.

</tr>.

<?php.

}.

?>.

<tr>.

<td class="main"><?php echo ENTRY_FIRST_NAME; ?></td>.

<td class="main">.

<?php.

If ($error == true) {.

If ($entry_firstname_error == true) {.

Echo tep_draw_input_field('customers_firstname', $cInfo->customers_firstname, 'maxlength="32"')'&nbsp;'ENTRY_FIRST_NAME_ERROR;.

} else {.

Echo $cInfo->customers_firstnametep_draw_hidden_field('customers_firstname');.

}.

} else {.

Echo tep_draw_input_field('customers_firstname', $cInfo->customers_firstname, 'maxlength="32"', true);.

}.

?></td>.

</tr>.

<tr>.

<td class="main"><?php echo ENTRY_LAST_NAME; ?></td>.

<td class="main">.

<?php.

If ($error == true) {.

If ($entry_lastname_error == true) {.

Echo tep_draw_input_field('customers_lastname', $cInfo->customers_lastname, 'maxlength="32"')'&nbsp;'ENTRY_LAST_NAME_ERROR;.

} else {.

Echo $cInfo->customers_lastnametep_draw_hidden_field('customers_lastname');.

}.

} else {.

Echo tep_draw_input_field('customers_lastname', $cInfo->customers_lastname, 'maxlength="32"', true);.

}.

?></td>.

</tr>.

<tr>.

<td class="main"><b><font color="#ff0000"><?php echo 'SOURCE'; ?></font></b></td>.

<td class="main">.

<?php.

Echo $cInfo->sourcetep_draw_hidden_field('source');.

?></td>.

</tr>.

<?php.

If (ACCOUNT_DOB == 'true') {.

?>.

<tr>.

<td class="main"><?php echo ENTRY_DATE_OF_BIRTH; ?></td>.

<td class="main">.

<?php.

If ($error == true) {.

If ($entry_date_of_birth_error == true) {.

Echo tep_draw_input_field('customers_dob', tep_date_short($cInfo->customers_dob), 'maxlength="10"')'&nbsp;'ENTRY_DATE_OF_BIRTH_ERROR;.

} else {.

Echo $cInfo->customers_dobtep_draw_hidden_field('customers_dob');.

}.

} else {.

Echo tep_draw_input_field('customers_dob', tep_date_short($cInfo->customers_dob), 'maxlength="10"', true);.

}.

?></td>.

</tr>.

<?php.

}.

?>.

<tr>.

<td class="main"><?php echo ENTRY_EMAIL_ADDRESS; ?></td>.

<td class="main">.

<?php.

If ($error == true) {.

If ($entry_email_address_error == true) {.

Echo tep_draw_input_field('customers_email_address', $cInfo->customers_email_address, 'maxlength="96"')'&nbsp;'ENTRY_EMAIL_ADDRESS_ERROR;.

} elseif ($entry_email_address_check_error == true) {.

Echo tep_draw_input_field('customers_email_address', $cInfo->customers_email_address, 'maxlength="96"')'&nbsp;'ENTRY_EMAIL_ADDRESS_CHECK_ERROR;.

} elseif ($entry_email_address_exists == true) {.

Echo tep_draw_input_field('customers_email_address', $cInfo->customers_email_address, 'maxlength="96"')'&nbsp;'ENTRY_EMAIL_ADDRESS_ERROR_EXISTS;.

} else {.

Echo $customers_email_addresstep_draw_hidden_field('customers_email_address');.

}.

} else {.

Echo tep_draw_input_field('customers_email_address', $cInfo->customers_email_address, 'maxlength="96"', true);.

}.

?></td>.

</tr>.

</table></td>.

</tr>.

<?php.

If (ACCOUNT_COMPANY == 'true') {.

?>.

<tr>.

<td><?php echo tep_draw_separator('pixel_trans.gif', '1', '10'); ?></td>.

</tr>.

<tr>.

<td class="formAreaTitle"><?php echo CATEGORY_COMPANY; ?></td>.

</tr>.

<tr>.

<td class="formArea"><table border="0" cellspacing="2" cellpadding="2">.

<tr>.

<td class="main"><?php echo ENTRY_COMPANY; ?></td>.

<td class="main">.

<?php.

If ($error == true) {.

If ($entry_company_error == true) {.

Echo tep_draw_input_field('entry_company', $cInfo->entry_company, 'maxlength="32"')'&nbsp;'ENTRY_COMPANY_ERROR;.

} else {.

Echo $cInfo->entry_companytep_draw_hidden_field('entry_company');.

}.

} else {.

Echo tep_draw_input_field('entry_company', $cInfo->entry_company, 'maxlength="32"');.

}.

?></td>.

</tr>.

</table></td>.

</tr>.

<?php.

}.

?>.

<tr>.

<td><?php echo tep_draw_separator('pixel_trans.gif', '1', '10'); ?></td>.

</tr>.

<tr>.

<td class="formAreaTitle"><?php echo CATEGORY_ADDRESS; ?></td>.

</tr>.

<tr>.

<td class="formArea"><table border="0" cellspacing="2" cellpadding="2">.

<tr>.

<td class="main"><?php echo ENTRY_STREET_ADDRESS; ?></td>.

<td class="main">.

<?php.

If ($error == true) {.

If ($entry_street_address_error == true) {.

Echo tep_draw_input_field('entry_street_address', $cInfo->entry_street_address, 'maxlength="64"')'&nbsp;'ENTRY_STREET_ADDRESS_ERROR;.

} else {.

Echo $cInfo->entry_street_addresstep_draw_hidden_field('entry_street_address');.

}.

} else {.

Echo tep_draw_input_field('entry_street_address', $cInfo->entry_street_address, 'maxlength="64"', true);.

}.

?></td>.

</tr>.

<?php.

If (ACCOUNT_SUBURB == 'true') {.

?>.

<tr>.

<td class="main"><?php echo ENTRY_SUBURB; ?></td>.

<td class="main">.

<?php.

If ($error == true) {.

If ($entry_suburb_error == true) {.

Echo tep_draw_input_field('suburb', $cInfo->entry_suburb, 'maxlength="32"')'&nbsp;'ENTRY_SUBURB_ERROR;.

} else {.

Echo $cInfo->entry_suburbtep_draw_hidden_field('entry_suburb');.

}.

} else {.

Echo tep_draw_input_field('entry_suburb', $cInfo->entry_suburb, 'maxlength="32"');.

}.

?></td>.

</tr>.

<?php.

}.

?>.

<tr>.

<td class="main"><?php echo ENTRY_POST_CODE; ?></td>.

<td class="main">.

<?php.

If ($error == true) {.

If ($entry_post_code_error == true) {.

Echo tep_draw_input_field('entry_postcode', $cInfo->entry_postcode, 'maxlength="8"')'&nbsp;'ENTRY_POST_CODE_ERROR;.

} else {.

Echo $cInfo->entry_postcodetep_draw_hidden_field('entry_postcode');.

}.

} else {.

Echo tep_draw_input_field('entry_postcode', $cInfo->entry_postcode, 'maxlength="8"', true);.

}.

?></td>.

</tr>.

<tr>.

<td class="main"><?php echo ENTRY_CITY; ?></td>.

<td class="main">.

<?php.

If ($error == true) {.

If ($entry_city_error == true) {.

Echo tep_draw_input_field('entry_city', $cInfo->entry_city, 'maxlength="32"')'&nbsp;'ENTRY_CITY_ERROR;.

} else {.

Echo $cInfo->entry_citytep_draw_hidden_field('entry_city');.

}.

} else {.

Echo tep_draw_input_field('entry_city', $cInfo->entry_city, 'maxlength="32"', true);.

}.

?></td>.

</tr>.

<?php.

If (ACCOUNT_STATE == 'true') {.

?>.

<tr>.

<td class="main"><?php echo ENTRY_STATE; ?></td>.

<td class="main">.

<?php.

$entry_state = tep_get_zone_name($cInfo->entry_country_id, $cInfo->entry_zone_id, $cInfo->entry_state);.

If ($error == true) {.

If ($entry_state_error == 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 = '"tep_db_input($cInfo->entry_country_id)"' 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('entry_state', $zones_array)'&nbsp;'ENTRY_STATE_ERROR;.

} else {.

Echo tep_draw_input_field('entry_state', tep_get_zone_name($cInfo->entry_country_id, $cInfo->entry_zone_id, $cInfo->entry_state))'&nbsp;'ENTRY_STATE_ERROR;.

}.

} else {.

Echo $entry_statetep_draw_hidden_field('entry_zone_id')tep_draw_hidden_field('entry_state');.

}.

} else {.

Echo tep_draw_input_field('entry_state', tep_get_zone_name($cInfo->entry_country_id, $cInfo->entry_zone_id, $cInfo->entry_state));.

}.

?></td>.

</tr>.

<?php.

}.

?>.

<tr>.

<td class="main"><?php echo ENTRY_COUNTRY; ?></td>.

<td class="main">.

<?php.

If ($error == true) {.

If ($entry_country_error == true) {.

Echo tep_draw_pull_down_menu('entry_country_id', tep_get_countries(), $cInfo->entry_country_id)'&nbsp;'ENTRY_COUNTRY_ERROR;.

} else {.

Echo tep_get_country_name($cInfo->entry_country_id)tep_draw_hidden_field('entry_country_id');.

}.

} else {.

Echo tep_draw_pull_down_menu('entry_country_id', tep_get_countries(), $cInfo->entry_country_id);.

}.

?></td>.

</tr>.

</table></td>.

</tr>.

<tr>.

<td><?php echo tep_draw_separator('pixel_trans.gif', '1', '10'); ?></td>.

</tr>.

<tr>.

<td class="formAreaTitle"><?php echo CATEGORY_CONTACT; ?></td>.

</tr>.

<tr>.

<td class="formArea"><table border="0" cellspacing="2" cellpadding="2">.

<tr>.

<td class="main"><?php echo ENTRY_TELEPHONE_NUMBER; ?></td>.

<td class="main">.

<?php.

If ($error == true) {.

If ($entry_telephone_error == true) {.

Echo tep_draw_input_field('customers_telephone', $cInfo->customers_telephone, 'maxlength="32"')'&nbsp;'ENTRY_TELEPHONE_NUMBER_ERROR;.

} else {.

Echo $cInfo->customers_telephonetep_draw_hidden_field('customers_telephone');.

}.

} else {.

Echo tep_draw_input_field('customers_telephone', $cInfo->customers_telephone, 'maxlength="32"', true);.

}.

?></td>.

</tr>.

<tr>.

<td class="main"><?php echo ENTRY_FAX_NUMBER; ?></td>.

<td class="main">.

<?php.

If ($processed == true) {.

Echo $cInfo->customers_faxtep_draw_hidden_field('customers_fax');.

} else {.

Echo tep_draw_input_field('customers_fax', $cInfo->customers_fax, 'maxlength="32"');.

}.

?></td>.

</tr>.

</table></td>.

</tr>.

<tr>.

<td><?php echo tep_draw_separator('pixel_trans.gif', '1', '10'); ?></td>.

</tr>.

<tr>.

<td class="formAreaTitle"><?php echo CATEGORY_OPTIONS; ?></td>.

</tr>.

<tr>.

<td class="formArea"><table border="0" cellspacing="2" cellpadding="2">.

<tr>.

<td class="main"><?php echo ENTRY_NEWSLETTER; ?></td>.

<td class="main">.

<?php.

If ($processed == true) {.

If ($cInfo->customers_newsletter == '1') {.

Echo ENTRY_NEWSLETTER_YES;.

} else {.

Echo ENTRY_NEWSLETTER_NO;.

}.

Echo tep_draw_hidden_field('customers_newsletter');.

} else {.

Echo tep_draw_pull_down_menu('customers_newsletter', $newsletter_array, (($cInfo->customers_newsletter == '1') ? '1' : '0'));.

}.

?></td>.

</tr>.

</table></td>.

</tr>.

<tr>.

<td><?php echo tep_draw_separator('pixel_trans.gif', '1', '10'); ?></td>.

</tr>.

<tr>.

<td align="right" class="main"><?php echo tep_image_submit('button_update.gif', IMAGE_UPDATE)' <a href="'tep_href_link(FILENAME_CUSTOMERS, tep_get_all_get_params(array('action'))) .'">'tep_image_button('button_cancel.gif', IMAGE_CANCEL)'</a>'; ?></td>.

</tr></form>.

<?php.

} else {.

?>.

<tr>.

<td><table border="0" width="100%" cellspacing="0" cellpadding="0">.

<tr><?php echo tep_draw_form('search', FILENAME_CUSTOMERS, '', 'get'); ?>.

<td class="pageHeading"><?php echo HEADING_TITLE; ?></td>.

<td class="pageHeading" align="right"><?php echo tep_draw_separator('pixel_trans.gif', 1, HEADING_IMAGE_HEIGHT); ?></td>.

<td class="smallText" align="right"><?php echo HEADING_TITLE_SEARCH' 'tep_draw_input_field('search'); ?></td>.

</form></tr>.

</table></td>.

</tr>.

<tr>.

<td><table border="0" width="100%" cellspacing="0" cellpadding="0">.

<tr>.

<td valign="top"><table border="0" width="100%" cellspacing="0" cellpadding="2">.

<tr class="dataTableHeadingRow">.

<td class="dataTableHeadingContent"><?php echo TABLE_HEADING_LASTNAME; ?></td>.

<td class="dataTableHeadingContent"><?php echo TABLE_HEADING_FIRSTNAME; ?></td>.

<td class="dataTableHeadingContent" align="right"><?php echo TABLE_HEADING_ACCOUNT_CREATED; ?></td>.

<td class="dataTableHeadingContent" align="center"><?php echo 'Customer Source'; ?></td>.

<td class="dataTableHeadingContent" align="right"><?php echo TABLE_HEADING_ACTION; ?>&nbsp;</td>.

</tr>.

<?php.

$search = '';.

If (isset($HTTP_GET_VARS['search']) && tep_not_null($HTTP_GET_VARS['search'])) {.

$keywords = tep_db_input(tep_db_prepare_input($HTTP_GET_VARS['search']));.

$search = "where c.customers_lastname like '%"$keywords"%' or c.customers_firstname like '%"$keywords"%' or c.customers_email_address like '%"$keywords"%'";.

}.

$customers_query_raw = "select c.customers_id, c.source, c.customers_lastname, c.customers_firstname, c.customers_email_address, a.entry_country_id from "TABLE_CUSTOMERS" c left join "TABLE_ADDRESS_BOOK" a on c.customers_id = a.customers_id and c.customers_default_address_id = a.address_book_id "$search" order by c.source desc, c.customers_lastname, c.customers_firstname";.

$customers_split = new splitPageResults($HTTP_GET_VARS['page'], MAX_DISPLAY_SEARCH_RESULTS, $customers_query_raw, $customers_query_numrows);.

$customers_query = tep_db_query($customers_query_raw);.

While ($customers = tep_db_fetch_array($customers_query)) {.

$info_query = tep_db_query("select customers_info_date_account_created as date_account_created, customers_info_date_account_last_modified as date_account_last_modified, customers_info_date_of_last_logon as date_last_logon, customers_info_number_of_logons as number_of_logons from "TABLE_CUSTOMERS_INFO" where customers_info_id = '"$customers['customers_id']"'");.

$info = tep_db_fetch_array($info_query);.

If ((!isset($HTTP_GET_VARS['cID']) || (isset($HTTP_GET_VARS['cID']) && ($HTTP_GET_VARS['cID'] == $customers['customers_id']))) && !isset($cInfo)) {.

$country_query = tep_db_query("select countries_name from "TABLE_COUNTRIES" where countries_id = '"(int)$customers['entry_country_id']"'");.

$country = tep_db_fetch_array($country_query);.

$reviews_query = tep_db_query("select count(*) as number_of_reviews from "TABLE_REVIEWS" where customers_id = '"(int)$customers['customers_id']"'");.

$reviews = tep_db_fetch_array($reviews_query);.

$customer_info = array_merge($country, $info, $reviews);.

$cInfo_array = array_merge($customers, $customer_info);.

$cInfo = new objectInfo($cInfo_array);.

}.

If (isset($cInfo) && is_object($cInfo) && ($customers['customers_id'] == $cInfo->customers_id)) {.

Echo ' <tr id="defaultSelected" class="dataTableRowSelected" onmouseover="rowOverEffect(this)" onmouseout="rowOutEffect(this)" onclick="document.location.href=\''tep_href_link(FILENAME_CUSTOMERS, tep_get_all_get_params(array('cID', 'action'))'cID='$cInfo->customers_id'&action=edit')'\'">'"\n";.

} else {.

Echo ' <tr class="dataTableRow" onmouseover="rowOverEffect(this)" onmouseout="rowOutEffect(this)" onclick="document.location.href=\''tep_href_link(FILENAME_CUSTOMERS, tep_get_all_get_params(array('cID'))'cID='$customers['customers_id'])'\'">'"\n";.

}.

?>.

<td class="dataTableContent"><?php echo $customers['customers_lastname']; ?></td>.

<td class="dataTableContent"><?php echo $customers['customers_firstname']; ?></td>.

<td class="dataTableContent" align="right"><?php echo tep_date_short($info['date_account_created']); ?></td>.

<td class="dataTableContent" align="center"><?php echo $customers['source']; ?></td>.

<td class="dataTableContent" align="right"><?php if (isset($cInfo) && is_object($cInfo) && ($customers['customers_id'] == $cInfo->customers_id)) { echo tep_image(DIR_WS_IMAGES'icon_arrow_right.gif', ''); } else { echo '<a href="'tep_href_link(FILENAME_CUSTOMERS, tep_get_all_get_params(array('cID'))'cID='$customers['customers_id'])'">'tep_image(DIR_WS_IMAGES'icon_info.gif', IMAGE_ICON_INFO)'</a>'; } ?>&nbsp;</td>.

</tr>.

<?php.

}.

?>.

<tr>.

<td colspan="4"><table border="0" width="100%" cellspacing="0" cellpadding="2">.

<tr>.

<td class="smallText" valign="top"><?php echo $customers_split->display_count($customers_query_numrows, MAX_DISPLAY_SEARCH_RESULTS, $HTTP_GET_VARS['page'], TEXT_DISPLAY_NUMBER_OF_CUSTOMERS); ?></td>.

<td class="smallText" align="right"><?php echo $customers_split->display_links($customers_query_numrows, MAX_DISPLAY_SEARCH_RESULTS, MAX_DISPLAY_PAGE_LINKS, $HTTP_GET_VARS['page'], tep_get_all_get_params(array('page', 'info', 'x', 'y', 'cID'))); ?></td>.

</tr>.

<?php.

If (isset($HTTP_GET_VARS['search']) && tep_not_null($HTTP_GET_VARS['search'])) {.

?>.

<tr>.

<td align="right" colspan="2"><?php echo '<a href="'tep_href_link(FILENAME_CUSTOMERS)'">'tep_image_button('button_reset.gif', IMAGE_RESET)'</a>'; ?></td>.

</tr>.

<?php.

}.

?>.

</table></td>.

</tr>.

</table></td>.

<?php.

$heading = array();.

$contents = array();.

Switch ($action) {.

Case 'confirm':.

$heading[] = array('text' => '<b>'TEXT_INFO_HEADING_DELETE_CUSTOMER'</b>');.

$contents = array('form' => tep_draw_form('customers', FILENAME_CUSTOMERS, tep_get_all_get_params(array('cID', 'action'))'cID='$cInfo->customers_id'&action=deleteconfirm'));.

$contents[] = array('text' => TEXT_DELETE_INTRO'<br><br><b>'$cInfo->customers_firstname' '$cInfo->customers_lastname'</b>');.

If (isset($cInfo->number_of_reviews) && ($cInfo->number_of_reviews) > 0) $contents[] = array('text' => '<br>'tep_draw_checkbox_field('delete_reviews', 'on', true)' 'sprintf(TEXT_DELETE_REVIEWS, $cInfo->number_of_reviews));.

$contents[] = array('align' => 'center', 'text' => '<br>'tep_image_submit('button_delete.gif', IMAGE_DELETE)' <a href="'tep_href_link(FILENAME_CUSTOMERS, tep_get_all_get_params(array('cID', 'action'))'cID='$cInfo->customers_id)'">'tep_image_button('button_cancel.gif', IMAGE_CANCEL)'</a>');.

Break;.

Default:.

If (isset($cInfo) && is_object($cInfo)) {.

$heading[] = array('text' => '<b>'$cInfo->customers_firstname' '$cInfo->customers_lastname'</b>');.

$contents[] = array('align' => 'center', 'text' => '<a href="'tep_href_link(FILENAME_CUSTOMERS, tep_get_all_get_params(array('cID', 'action'))'cID='$cInfo->customers_id'&action=edit')'">'tep_image_button('button_edit.gif', IMAGE_EDIT)'</a> <a href="'tep_href_link(FILENAME_CUSTOMERS, tep_get_all_get_params(array('cID', 'action'))'cID='$cInfo->customers_id'&action=confirm')'">'tep_image_button('button_delete.gif', IMAGE_DELETE)'</a> <a href="'tep_href_link(FILENAME_ORDERS, 'cID='$cInfo->customers_id)'">'tep_image_button('button_orders.gif', IMAGE_ORDERS)'</a> <a href="'tep_href_link(FILENAME_MAIL, 'selected_box=tools&customer='$cInfo->customers_email_address)'">'tep_image_button('button_email.gif', IMAGE_EMAIL)'</a>');.

$contents[] = array('text' => '<br>'TEXT_DATE_ACCOUNT_CREATED' 'tep_date_short($cInfo->date_account_created));.

$contents[] = array('text' => '<br>'TEXT_DATE_ACCOUNT_LAST_MODIFIED' 'tep_date_short($cInfo->date_account_last_modified));.

$contents[] = array('text' => '<br>'TEXT_INFO_DATE_LAST_LOGON' 'tep_date_short($cInfo->date_last_logon));.

$contents[] = array('text' => '<br>'TEXT_INFO_NUMBER_OF_LOGONS' '$cInfo->number_of_logons);.

$contents[] = array('text' => '<br>'TEXT_INFO_COUNTRY' '$cInfo->countries_name);.

$contents[] = array('text' => '<br>'TEXT_INFO_NUMBER_OF_REVIEWS' '$cInfo->number_of_reviews);.

}.

Break;.

}.

If ( (tep_not_null($heading)) && (tep_not_null($contents)) ) {.

Echo ' <td width="25%" valign="top">'"\n";.

$box = new box;.

Echo $box->infoBox($heading, $contents);.

Echo ' </td>'"\n";.

}.

?>.

</tr>.

</table></td>.

</tr>.

<?php.

}.

?>.

</table></td>.

<! body_text_eof //>.

</tr>.

</table>.

<! body_eof //>.

<! footer //>.

<?php require(DIR_WS_INCLUDES'footer.php'); ?>.

<! footer_eof //>.

<br>.

</body>.

</html>.

<?php require(DIR_WS_INCLUDES'application_bottom.php'); ?>..

Comment #12

Thanks for the help, I figured it out now...

But I have another question..

How can I make account_edit so that people can edit there company name and adress and other things that are in adress_book..

I cant figur out how I can do this....

Comment #13

Hello!.

How can I change the create_account.php file. I dont want people to put in there gender at all, and I want some new things there to.. but when I try to get ried of gender the page want appear. it's just blank..

Is there someone that can help me with this??.

Regards Thomas..

Comment #14

You need to edit create_account.php and create_account_process.php in tandem...

Comment #15


This question was taken from a support group/message board and re-posted here so others can learn from it.