Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

fast easy checkout


nana

Recommended Posts

Okay.. I just replaced the file with the new fast_account.php and made changes to creat_account.php & creat_account3.php mentioned in your comment to Tom and I no longer get an error message.

 

Now... when I go to checkout, on the order form I still see log in or account creation related messages (such as "if you want to log in, go to log in page" on the top of order form / checkbox at the bottom of the order form asking whether to create an account). Which files should I amend to get rid of these messages?

 

Also, after I fill out the order form on the checkout page and continue on the next steps, I see a "log off" message on the top as though by entering the information on the checkout form I somehow get "logged in". When I click on the "log off" link, I get logged off. If I were a customer I'd personally think that I shouldn't be logged in when I haven't created any account with the website. Would there be any way to prevent this unintended log in feature?

Link to comment
Share on other sites

  • Replies 1.7k
  • Created
  • Last Reply

Top Posters In This Topic

Hi Frank:

 

First, I just want to thank you for your amazing contribution, both the contribution and the energy that you spend working thru it with everyone:

 

1) 80% of my customers have diff. shipping and billing so I want to combine the billing and shipping addresses in one screen. This occurs with my current (non-oscommerce site)(I have changed address on my payment screen to say BILLING address. so people know its' really necessary, not just that I want to get an address out of them).

 

2) isn't the billing address used to validate the CC? That's why I changed it to Biling address, as opposed to just 'your address'

 

2) I realize the login and account are not about cc info. I just want them to be able to 'log in' without having to create a password, unless they WANT to create an account that brings their info back in shipping options. Am I making sense? The only thing that matters to me, really, is their email address. But, they might want me to retain their shipping address..Im just trying to leave that up to them, as opposed to forcing them to do an account.

1-you can change the wording in the language files

2-b ofcourse you can remove the need of the password but then all you need to know is the customers email to login to their account and at least access their order history

or you can change the wording of create account to something else like remmember me

other than that i really do not understand what you want to do.

Link to comment
Share on other sites

Frank (aka nana),

 

I've decided to give it another try with FEC, just like I did with PWA - which I got working...

 

But, I don't like the layout of your new version's create_account found at http://seelily.com/create_account.php

 

To me it's too busy and potentially confusing to a customer who wants to get in and get out quick. But hey, who am I? A jerk? :P

 

So, I'm going to start with 2.0 and just take it really slow.

 

I wish you were on ICQ or MSN Messenger or something...

 

I'll report back when I'm stumped.

Link to comment
Share on other sites

Frank,

 

I've decided to go with V3.1 thanks to your post.

 

First stumping point:

Below is code from my checkout_confirmation.php page which is modified for CCGV. As you can see it doesn't jive with your instructions from part-1.html which say "right before this code around line 67..."

//  if ( ( is_array($payment_modules->modules) && (sizeof($payment_modules->modules) > 1) && !is_object($$payment) ) || (is_object($$payment) && ($$payment->enabled == false)) ) {
 if ( (is_array($payment_modules->modules)) && (sizeof($payment_modules->modules) > 1) && (!is_object($$payment)) && (!$credit_covers) ) {
// ################# End Added CGV Contribution ##################"
tep_redirect(tep_href_link(FILENAME_CHECKOUT_PAYMENT, 'error_message=' . urlencode(ERROR_NO_PAYMENT_MODULE_SELECTED), 'SSL'));
 }

 

The reason it doesn't jive is because CCGV comments out the line which you say to add to.

 

So, if I do the following is it correct?

if ( (is_array($payment_modules->modules)) && (sizeof($payment_modules->modules) > 1) && (!is_object($$payment)) && (!$credit_covers) ) {
// ################# End Added CGV Contribution ##################"
tep_redirect(tep_href_link(FILENAME_CHECKOUT_PAYMENT, 'error_message=' . urlencode(ERROR_NO_PAYMENT_MODULE_SELECTED), 'SSL'));
/// fec for get total
$paynow = tep_db_prepare_input($HTTP_GET_VARS['paynow']);
if ($paynow ==3) {
tep_redirect(tep_href_link(FILENAME_CHECKOUT_SHIPPING, 'show_total=1&error_message=' . urlencode(ERROR_TOTAL_NOW), 'SSL'));
 }

Link to comment
Share on other sites

Frank,

 

Did that - it's smack dab in the middle of a CCGV mod though. Below is the full block...

 

// ################# Added CGV Contribution ##################"
// CCGV Contribution
 $order_total_modules = new order_total;
 $order_total_modules->collect_posts();
 $order_total_modules->pre_confirmation_check();
/// #################BEGIN fec for get total
$paynow = tep_db_prepare_input($HTTP_GET_VARS['paynow']);
if ($paynow ==3) {
tep_redirect(tep_href_link(FILENAME_CHECKOUT_SHIPPING, 'show_total=1&error_message=' . urlencode(ERROR_TOTAL_NOW), 'SSL'));
 }
/// ##########END fec for get total
//  if ( ( is_array($payment_modules->modules) && (sizeof($payment_modules->modules) > 1) && !is_object($$payment) ) || (is_object($$payment) && ($$payment->enabled == false)) ) {
 if ( (is_array($payment_modules->modules)) && (sizeof($payment_modules->modules) > 1) && (!is_object($$payment)) && (!$credit_covers) ) {
// ################# End Added CGV Contribution ##################"

 

Now, i'm on the part which talks about uploading the checkout_shipping. This file is also heavily modified for CCGV.

 

So, is your checkout_shipping a combination of checkout_shipping and checkout_payment? If so, whatever modifications I currently have in each file I need to add to your checkout_shipping, right?

Link to comment
Share on other sites

Frank,

 

It sounds like I'm an ass with all the questions I'm asking and for that I apologize.

 

Your instructions from part2 (file named part-3.html) say to replace create_account.php. However, my file is heavily modified. I searched thru your create_account.php file hoping for your commented code that I could easily snip into mine and there's no mention of FEC so I'm kind of hosed there.

 

And, I don't think my create_account file is heavily commented either so I may be doomed. :blush:

 

In either event, your contribution is very nice and your responsiveness is awesome - kudos!

Link to comment
Share on other sites

In part-2 (file named part-3.html) you say that in logoff.php around line 63 to change

<td class="main"><?php if echo TEXT_MAIN; ?></td>

 

However, the actual line is:

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

 

Notice the "if". Does this matter?

Edited by tomed8
Link to comment
Share on other sites

Awesome! It works... almost. I get thru the entire purchase but the checkout_success file doesn't display in the browser. When I check my php error log I see the following:

[01-Dec-2005 17:13:57] PHP Parse error: syntax error, unexpected '}' in c:\program files\apache group\Apache\htdocs\store.working.ccgv.fec\checkout_success.php on line 19

 

Here's the code that it is complaining about about line 19 is

if(tep_session_is_registered('createaccount')) tep_redirect(tep_href_link('account_password_new.php','thx=1'));}

 

 

// if the customer is not logged on, redirect them to the shopping cart page
 if (!tep_session_is_registered('customer_id')) {
tep_redirect(tep_href_link(FILENAME_SHOPPING_CART));
 }
if(tep_session_is_registered('createaccount')) tep_redirect(tep_href_link('account_password_new.php','thx=1'));}
 if (isset($HTTP_GET_VARS['action']) && ($HTTP_GET_VARS['action'] == 'update')) {
$notify_string = 'action=notify&';
$notify = $HTTP_POST_VARS['notify'];
if (!is_array($notify)) $notify = array($notify);
for ($i=0, $n=sizeof($notify); $i<$n; $i++) {
  $notify_string .= 'notify[]=' . $notify[$i] . '&';
}
if (strlen($notify_string) > 0) $notify_string = substr($notify_string, 0, -1);

tep_redirect(tep_href_link(FILENAME_DEFAULT, $notify_string));
 }

 

It's soooo close.

 

Ideas?

Edited by tomed8
Link to comment
Share on other sites

Alright, since the following in part-3.html was optional, I've removed it to verify FEC will work and it does!

------------------------------

in checkout_success.php

around line 16 AFTER

if (!tep_session_is_registered('customer_id')) {
tep_redirect(tep_href_link(FILENAME_SHOPPING_CART));
 }

ADD IF YOU WANT TO OFFER SECOND CHANCE ACCOUNT AFTER PURCHASE

 if(tep_session_is_registered('createaccount')) tep_redirect(tep_href_link('account_password_new.php','thx=1'));}

------------------------------

But, I'd like to implement all the functionality because you (frank) spent a ton of time on it!

 

Any ideas?

 

Also, in a previous post you mentioned that a customer could be entered into the "customers" table and that an account could automatically be created for him/her with a random password which could be emailed to them.

 

How do you do that?

 

Sorry for dominating this thread for the past several hours but, it is "support" after all.

:-"

 

This is an amazing contribution - I like it much more than PWA. Now I've just got to get the few pieces that I don't have working all fixed. B)

Link to comment
Share on other sites

[01-Dec-2005 17:13:57] PHP Parse error: syntax error, unexpected '}' in c:\program files\apache group\Apache\htdocs\store.working.ccgv.fec\checkout_success.php on line 19

 

Here's the code that it is complaining about about line 19 is

if(tep_session_is_registered('createaccount')) tep_redirect(tep_href_link('account_password_new.php','thx=1'));}

 

tomed8,

 

try removing the ending '}' in line 19. that seems to be misplaced.

 

michael

Link to comment
Share on other sites

Frank...

 

Perhaps I'm the guinnea pig that you need for v3.1.

 

When I implement the following line

 

if(tep_session_is_registered('createaccount')) tep_redirect(tep_href_link ('account_password_new.php','thx=1'));}

 

in checkout_success then checkout_success doesn't show in browser at purchase completion and the following error is written into my php error log

[01-Dec-2005 18:08:48] PHP Parse error: syntax error, unexpected '}' in c:\program files\apache group\Apache\htdocs\store.working.ccgv.fec\checkout_success.php on line 19

 

When I remove the line it works like a charm.

------------------

On checkout_success, when I click the "Create Account" in the header I get a blank browser and the following error is written into my php error log

[01-Dec-2005 18:08:48] PHP Parse error: syntax error, unexpected '{' in c:\program files\apache group\Apache\htdocs\store.working.ccgv.fec\account_password_new.php on line 237

 

What can I do to help you get this thing working correctly?

 

PHP Version: 5.0.4

HTTP Server: Apache/1.3.33 (Win32) mod_ssl/2.8.23 OpenSSL/0.9.8 PHP/5.0.4

Database: MySQL 4.1.14-nt

Link to comment
Share on other sites

ok tom

in checkout_success.php that line is there to redirect to a diffrent rather than checkout_success.php

this is there because some people do not want to offer the account before the customer has made the purchase.

in this page you will have a second chance to create an account.

what is in your checkout_success.php that you need

you might be able to take this back to account_password_new.php

or better yet you can just comment it out

 

as far as the password is concerned just look at the top of the create account page that you are using

there are some values that you can set to 0 and 1 depending which boxes you are going to use and how you want to do things

i have put simple direction in the file or just turn everything to 0

and look at the create account page and see what happends

then turn these values to 1 one at a time to see what happends

i made this version because diffrent people wanted the pages to do diffrent things so i made them module for the flexability

it is not meant to use every feature but to make it as close as how you want it to act.

Link to comment
Share on other sites

I couldn't find instructions for PWA in your install.html file:

 

 

" 2-The second part of contribution creates two different approach to account creation

A-Removes The necessity to create an account totally before purchase

B-Makes creating account optional "

 

 

Would I have to use the PWA contrib, or is it a matter of changing a few lines in your code?

 

 

 

Thanks for this. I will be sure to donate soon if I make any money from my store.

Link to comment
Share on other sites

Frank,

 

Thanks for the replies. I'm almost there.

 

Alright, here's the killer scenario for FEC:

  • A customer comes and buys without explicitly saying "Create an account."

  • Their data is written to the customers table with a random password and the createaccount field in the customers table for this customer is set to N.

  • Two months later we notify them that there is a software update and they return to the site to login and retrieve the software update.

  • Because they didn't create an account they can't login. Stranger still, their data exists in the customers table and when they enter their E-mail Address at password_forgotten.php they see the error "Error: The E-Mail Address was not found in our records, please try again"

  • HOWEVER, their data exists in the customers table with a password! It seems they'd be able to click "Log in" -> "Password forgotten? Click here" and the system would send their original random password which would allow them to login.

How can this be accomplished?

 

I've figured out that by manually setting the createaccount field to Y for a specific record which was previously N, then the person will be seen correctly by password_forgotten.php and the system will post the message "Success: A new password has been sent to your e-mail address."

 

This is exactly what is needed.

 

Now, how can this be set to occur programatically?

 

I see the following, but I'm no PHP programmer and have no idea how to manipulate this functionality.

  //START REGISTRATION CODE
$createaccount='N';
//next two lines gives you a temporary fixed password you can change to what you like
$password = tep_create_random_value(15);
$confirmation = $password;
 //start type one create assount

 if ($create_password == 1) {
 $createaccount = tep_db_prepare_input($HTTP_POST_VARS['createaccount']);
 if ($createaccount!='Y')$createaccount='N';
 }
 //start type two create account 
  if ($show_account_box == 1) {
 $createaccount = tep_db_prepare_input($HTTP_POST_VARS['createaccount']);
	 if ($createaccount=='Y') {
 $password = tep_db_prepare_input($HTTP_POST_VARS['password']);
	 $confirmation = tep_db_prepare_input($HTTP_POST_VARS['confirmation']);

Link to comment
Share on other sites

I couldn't find instructions for PWA in your install.html file:

" 2-The second part of contribution creates two different approach to account creation

A-Removes The necessity to create an account totally before purchase

B-Makes creating account optional "

Would I have to use the PWA contrib, or is it a matter of changing a few lines in your code?

Thanks for this. I will be sure to donate soon if I make any money from my store.

 

Lane,

this is a totally separate contribution from PWA - they do not correlate to one another. IMHO this contribution delivers the same functionality as PWAA, but gives you more options of how to customize:

  1. the user experience, giving them the option to create an account - multiple times, if you'd like - you can also turn this off
  2. customize the back-end so that if you'd like to treat the customer as a "customer" you can do so easily because the customer record is entered into the customers table, unlike PWA
  3. etc.

Link to comment
Share on other sites

lane you do not need the PWA for this contribution

this is a modified version of PWA +

it also reduces a step in checkout see the demo http://seelily.com

 

 

 

tom

i thought about your situation

first you have to make a modification that the account won't be erased in the create_account.php when they use the same email address but changed the createaccount field changed to something like [z] this way theystill won't be able to access it

then when the update available email is sent to them you can generate a new random password and reset the createaccount field to[y] this way they can get a password that works in the email.

you can also set it up that the createacount field is set back to [z] when the download is done

please have in mind that they can only login to one account at a time and you probably have multiple accounts for the same email address once for each purchase with a guest account.

but i guess you expect that

 

 

 

 

 

Frank,

 

Thanks for the replies. I'm almost there.

 

Alright, here's the killer scenario for FEC:

  • A customer comes and buys without explicitly saying "Create an account."

  • Their data is written to the customers table with a random password and the createaccount field in the customers table for this customer is set to N.

  • Two months later we notify them that there is a software update and they return to the site to login and retrieve the software update.

  • Because they didn't create an account they can't login. Stranger still, their data exists in the customers table and when they enter their E-mail Address at password_forgotten.php they see the error "Error: The E-Mail Address was not found in our records, please try again"

  • HOWEVER, their data exists in the customers table with a password! It seems they'd be able to click "Log in" -> "Password forgotten? Click here" and the system would send their original random password which would allow them to login.

How can this be accomplished?

 

I've figured out that by manually setting the createaccount field to Y for a specific record which was previously N, then the person will be seen correctly by password_forgotten.php and the system will post the message "Success: A new password has been sent to your e-mail address."

 

This is exactly what is needed.

 

Now, how can this be set to occur programatically?

 

I see the following, but I'm no PHP programmer and have no idea how to manipulate this functionality.

  //START REGISTRATION CODE
$createaccount='N';
//next two lines gives you a temporary fixed password you can change to what you like
$password = tep_create_random_value(15);
$confirmation = $password;
 //start type one create assount

 if ($create_password == 1) {
 $createaccount = tep_db_prepare_input($HTTP_POST_VARS['createaccount']);
 if ($createaccount!='Y')$createaccount='N';
 }
 //start type two create account 
  if ($show_account_box == 1) {
 $createaccount = tep_db_prepare_input($HTTP_POST_VARS['createaccount']);
	 if ($createaccount=='Y') {
 $password = tep_db_prepare_input($HTTP_POST_VARS['password']);
	 $confirmation = tep_db_prepare_input($HTTP_POST_VARS['confirmation']);

Link to comment
Share on other sites

tom

i thought about your situation

first you have to make a modification that the account won't be erased in the create_account.php when they use the same email address but changed the createaccount field changed to something like [z] this way theystill won't be able to access it

then when the update available email is sent to them you can generate a new random password and reset the createaccount field to[y] this way they can get a password that works in the email.

you can also set it up that the createacount field is set back to [z] when the download is done

please have in mind that they can only login to one account at a time and you probably have multiple accounts for the same email address once for each purchase with a guest account.

but i guess you expect that

Frank,

I'll never want an account to be erased. So, if setting the createaccount field to Y guarantees this, how can I programmatically set this?

1. I'll never have more than one account for a single customer.

2. I want them to login to get updated software, whether an account is explicitly created or not

3. Likelihood of a customer entering identical email as someone is too remote to care about.

 

Ideas?

Link to comment
Share on other sites

what if the customer comes in to your shop buys software A don't create an account and leaves.

he comes back in 3 months and wants to buy a diffrent software.

now how is he going to login without having a password

then he must be able to create a new account

so now two accounts same email

Link to comment
Share on other sites

Hi Frank: I'm just trying to set it up as a logical process where all points are clear when you first look at the page.

 

1-I have it set up now in language files as fastcheckout option...I like remember me better...

 

What Im trying to do:

 

a- allow people to purchase & signup for newsletter without creating an account but stlil capture their email in the db - with PWA, does that happen?

 

b-give people option to create an account to save their settings if they think they may want to return

 

Thats' it...I think it's pretty much there. Other than that, just usability focused, I'd liek the option to login, create or not create an account should be right at the top. But I guess that's just playing with the placement of the sections in the code.

 

It's a little confusing for a user to hit a login button in a shopping cart i thik without seeing that creating an account is an option. Sort of like there is some private club at the bottom.

 

If you remove password, someone could know a users email and use their billing info, correct? Or is that not stored - only shipping info?

 

Thanks, j

Link to comment
Share on other sites

diffrent people diffrent logic

it has both functionality that you want

you can move the boxes pretty easy

if the customer creates a non account and returns later his original non account erases and a new one is created. so there are not multiple accounts for the same email address.

you can add any other functionality you choose

Link to comment
Share on other sites

what if the customer comes in to your shop buys software A don't create an account and leaves.

he comes back in 3 months and wants to buy a diffrent software.

now how is he going to login without having a password

then he must be able to create a new account

so now two accounts same email

Frank,

 

If customer doesn't explicitly create an account, but implicitly one is created for him/her (which is what I advocate) then when they return to buy more software they'll get a message which says "Your email address is in our system. Either click here to login or enter a new email address to complete your order."

 

This way there's no ambiguity - buy once, customer for life.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...