Jump to content

Archived

This topic is now archived and is closed to further replies.

PupStar

One Page Checkout for osCommerce 2.3.1

Recommended Posts

could there be a possibility, using the admin panel, the store owner could select an OPC mode or even the buttons most appropriate for their particular store? Say maybe like some stores might not allow a guest account, some might desire a PWA mode.

 

Timmy C

Share this post


Link to post
Share on other sites

@@fulluvscents It worked great as far as I tried - I registered after adding stuff to cart, the only thing is it gave me a small box with 0 the first time I tried to checkout. Clicking it again worked properly.

Share this post


Link to post
Share on other sites

Anything is possible. In fact, I could just as easily stick to the basic login or create account that OSC was originally written with, and just keep the guest checkout for myself. Like I said, nothing is a one size fits all, but anything can be modified to suit a person's particular needs.

 

Box with a zero could have been me working on something, or it could have been a server communication error. It was an ajax error regardless, just not sure what it was, of course. If it was a while back, I know what it was, but if it was recently, I really don't know why you'd get a 0 since right now it's set up to throw back the error that it received (makes debugging easier).

Share this post


Link to post
Share on other sites

@@fulluvscents Sorry about this, but I found that error right after you posted about your rewrite here. I didn't immediately report it as I was distracted by something else and it slipped my mind, most embarrassingly.

Share this post


Link to post
Share on other sites

Have an issue getting the OPC page to go past "Continue" after filling in necessary information. Box pops-up stating to "relax while the order is processed," Never goes any farther; can close box out by clicking the close"X" in upper right corner. Also notice when the information is put-in and/or clicking the "upDate" button I get an ou of place statement at bottom of page explaining the order is updating. Really need to fix this guy. Any input would be appreciated.

 

here is the page: https://www.discountegauges.com/checkout.php

 

Thanks a bunch,

 

Timmy C

Share this post


Link to post
Share on other sites

Have an issue getting the OPC page to go past "Continue" after filling in necessary information. Box pops-up stating to "relax while the order is processed," Never goes any farther; can close box out by clicking the close"X" in upper right corner. Also notice when the information is put-in and/or clicking the "upDate" button I get an ou of place statement at bottom of page explaining the order is updating. Really need to fix this guy. Any input would be appreciated.

 

here is the page: https://www.discountegauges.com/checkout.php

 

Thanks a bunch,

 

Timmy C

 

Timmy, if I remember correctly I had issues with this and I found that I needed to move this code from the checkout.php file to the includes/template_top.php file

 

<!-- ONE PAGE START -->
<?php if (preg_match("/checkout.php/", $PHP_SELF)) {  ?>
<script type="text/javascript" language="javascript" src="ext/jquery/jquery.ajaxq-0.0.1.js"></script>
<script type="text/javascript" language="javascript" src="ext/jquery/jQuery.pstrength.js"></script>
<script type="text/javascript" language="javascript" src="ext/jquery/ajax_search_suggest.js"></script>
<script type="text/javascript" language="javascript" src="includes/checkout/checkout.js"></script>
<?php } ?>
<!-- ONE PAGE END -->
<?php echo $oscTemplate->getBlocks('header_tags'); ?>
<!-- ONE PAGE START -->
<?php if (preg_match("/checkout.php/", $PHP_SELF)) {  ?>

 

obviously that is not all the code for OPC just the first part, move all OPC code and see what happens.

 

Mark


Bootstrap 3 ROCKS!

(or it will if I ever get my head around it lol)

(and I think I have now (w00t) )

Share this post


Link to post
Share on other sites

Mark... Thanks a bunch, I'll try it later this evening, Gotta get the laundry room floor tile installed, as the new washer/dryer has been delivered!

 

Timmy C

Share this post


Link to post
Share on other sites

Mark... Thanks a bunch, I'll try it later this evening, Gotta get the laundry room floor tile installed, as the new washer/dryer has been delivered!

 

Timmy C

 

no gurantees just a stab in the dark


Bootstrap 3 ROCKS!

(or it will if I ever get my head around it lol)

(and I think I have now (w00t) )

Share this post


Link to post
Share on other sites

In the opc that's been contributed, all the jquery had to be moved to template_top.php - I don't know why, since the one I wrote has all the code in one page. But, it is what it is.

 

@oxwivi and @kymation Guest checkout IS an admin option. That's the way it's setup. There are only two admin options - turn the checkout on or off, allow or don't allow guest checkout. I don't know why it slipped my mind to mention that. Actually, I think I forgot that I set that up as optional.

 

I'll turn it off for a while for anyone who wants to check it out without the guest option turned on.

Share this post


Link to post
Share on other sites

@mumme - could you recheck the page now, and see if the transition to the checkout page is better now? If you notice any content still showing while it shouldn't be (or vice versa), let me know.

 

I'm thinking that I need to start a new thread soon. Things are starting to get confusing around here.

Share this post


Link to post
Share on other sites

Apparently, I have to be logged into my PP sandbox account before anyone can test it. Sucks b/c PayPal works better than it EVER did with the old OPC.

 

I think I've hit everything, except hiding guests from the knowledge that an account was created in the background. If not, remind me what I missed.

Share this post


Link to post
Share on other sites

Mark... Checked out checkout.php and includes/template_top.php.. The code you posted is already in the template_top.php with the exception of this line:

 

<script type="text/javascript" language="javascript" src="ext/jquery/ajax_search_suggest.js"></script>

 

Is this the line that might be causing the extended relaxation period, waiting for the order to compile?

 

Timmy C

Share this post


Link to post
Share on other sites

I am not sure if that will be the cause of the checkout problems but you should really move that line to template_top.php]

 

Also if you have other javascript in your template_top.php it could be that they are conflicting and may need moving around as I know that when I added the google+1 script to the template_top.php I had to move it above the fancybox script because it conflicted.

 

Mark


Bootstrap 3 ROCKS!

(or it will if I ever get my head around it lol)

(and I think I have now (w00t) )

Share this post


Link to post
Share on other sites

@@fulluvscents

  • The div dosent shows up before the loginbox, but the checkout,php is empty in 4-5 seconds before the login-box becomes visible.
    Maybe it is possible to have a nice loading animation during the time it takes to load the login box?
    .
  • The loading / processing animation on checkout.php always gets on top of the page.
    To make it clearer to the user, maybe it looks nice to have a black 50% transparent background behind the animation box?
    (like when you open the CODE function here on the forum)
    .
  • In "password-forgotten", if you enter your email-adress and then click on confirm button you get a error massage: "please fill in all required fileds".
    So you must click on confirm button twice, you descelct the email field with tab-button or click with the mouse somwhere outside the field.
    (IE9)
    .
  • On the login-box, if I use the password I recived from "forgotten password" I cant get the requred field symbol to change from red to green.
    The password is 5 characters long, and it looks like the password needs to be 6 characters long to change the symbol.
    If i use the password 123456 it works, but if i use 12345 it dosent. So i cant login with the password I get from "forgotten password".
    .
  • Because I cant login I tried to make a new account and get some errors here:
    1, If I enter a password and press TAB it jumps to gender selection instead of Password Confirmation
    2, In the password field somethimes I must enter 6 characters to be able to "open" the password-confirmation field.
    And somethimes I must enter 8 characters. Strange. :)
    3, Even If im sure i entered exactly the same password in both fields, simple like 12345678 requerid filed symbol dosent changes. (on password confirmation field)
    .
  • I guess you are working on some changes, but If you didnt notice on shipping methods you have this:
    (and also a pop-up window with a lot of warnings)

Array ( [CONTENT_LENGTH] => 26 [CONTENT_TYPE] => application/x-www-form-urlencoded; charset=UTF-8 [DOCUMENT_ROOT] => /home/fulluv/public_html [GATEWAY_INTERFACE] => CGI/1.1 [HTTP_ACCEPT] => text/html, */* [HTTP_ACCEPT_ENCODING] => gzip, deflate [HTTP_ACCEPT_LANGUAGE] => sv [HTTP_CACHE_CONTROL] => no-cache [HTTP_CONNECTION] => Keep-Alive [HTTP_COOKIE] => osCsid=37267fe8369f4426a12fb97ed8c5de97 [HTTP_HOST] => fulluvscents.com [HTTP_REFERER] => http://fulluvscents.com/catalog/checkout.php [HTTP_USER_AGENT] => Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 6.1; WOW64; Trident/4.0; GTB0.0; SLCC2; .NET CLR 2.0.50727; .NET CLR 3.5.30729; .NET CLR 3.0.30729; Media Center PC 6.0; OfficeLiveConnector.1.3; OfficeLivePatch.0.0; .NET4.0C) [HTTP_X_REQUESTED_WITH] => XMLHttpRequest [PATH] => /bin:/usr/bin [QUERY_STRING] => [REDIRECT_STATUS] => 200 [REMOTE_ADDR] => 83.226.49.194 [REMOTE_PORT] => 58829 [REQUEST_METHOD] => POST [REQUEST_URI] => /catalog/checkout.php [sCRIPT_FILENAME] => /home/fulluv/public_html/catalog/checkout.php [sCRIPT_NAME] => /catalog/checkout.php [sERVER_ADDR] => 184.107.192.43 [sERVER_ADMIN] => webmaster@[member='fulluvscents'].com [sERVER_NAME] => fulluvscents.com [sERVER_PORT] => 80 [sERVER_PROTOCOL] => HTTP/1.1 [sERVER_SIGNATURE] =>
Apache Server at fulluvscents.com Port 80
[sERVER_SOFTWARE] => Apache [uNIQUE_ID] => Ty5bk7hrvzIAAEVkU8MAAAAR [php_SELF] => /catalog/checkout.php [REQUEST_TIME] => 1328438164 [argv] => Array ( ) [argc] => 0 )

  • I like the
     

    >>Click here to view shipping regulations for your country<<

    Great idea!
    (but for some shops maybe it should be possible to hide it through admin - if they only sell "legal" stuff, like... pens.. or something? =)

Very good work!

Share this post


Link to post
Share on other sites

Nice list. Thank you.

 

I'm gonna finish up my shipping mod hopefully tonight, and I will work on that list (plus fixing the guest checkout), and see if I can't get this checkout up and running, and tested on a couple other servers. Hopefully, I'll have it contributed within the week. While I've been working on the shipping mod, I've also run into little things in the checkout here and there that I've fixed along the way.

 

The shipping regulation info is specific to the USPS shipping method, not the checkout in general. So, I won't get into the details about that.

 

Appreciate the feedback.

Share this post


Link to post
Share on other sites

Jetta... Have a thought> Will there be a way to disable the current OPC1, as part of the OPC2 you are developing (of course, OPC can be disabled in the admin panel?) How will the drop-in ability effect , with say, a store that currently running OPC, or will it require a complete overhaul of the store? Is a "Magic Eraser" feature possible to remove OPC1? Would naming your OPC as say, OPC2 leave OPC laying dormant in the files once disabled in admin panel, just a simple admin enable of OPC2 and yer in business?

 

 

If there is a Golden OSCommerce Achievement award, it would be yours when you pull this guy off,

 

Timmy C

Share this post


Link to post
Share on other sites

@surrfman

 

Let's say for example, you did a complete drop on top and didn't touch OPC1. Ummm, yep, I think you could disable OPC1 from the admin panel, enable this, and you'd be good to go, but you wouldn't be able to switch back and forth. It would overwrite two files (checkout.php and it's associated language file). It uses a different configuration group ID, and different configuration keys than OPC1.

 

In fact, the entire thing is uh, let me see, TWO files. checkout.php and it's associated language file. Yeah, that's right, cause I am awesome like that.

There are THREE file modifications - to redirect checkout_shipping, checkout_payment, and checkout_configuration.

There is one very small sql statement adding TWO configurations

And there are two associated admin settings - turn it on/off, allow/disallow guests.

 

That's it. Easy as pie.

 

No changes to any of the payment/shipping modules. No changes to functions, no changes to anything you already have, except those three redirects. The intrusiveness, and scattered system that OPC1 was, is exactly why it was so buggy. It was jammed into a site and forced everything else to work around it. This is different in that regard because it was written specifically to work with what is already there.

 

 

Basically, if your shop will run with OPC1 turned off, then it will run after doing a drop on top with complete disregard for removing the old OPC.

"Golden OSCommerce Achievement award" - haha, yeah.

_____________________________

 

Good news. I got my shipping mod to a clean upload point, and I can step away from that and add my next upgrade later.

So, now, I can go back to this, and finish up those few little points of interest. Yes, I'm both OCD and ADD, but it all gets done.

 

If all goes well, I'll have THIS done within about 12 hours, 24 at the most.

Share this post


Link to post
Share on other sites

@mumme

 

The div dosent shows up before the loginbox, but the checkout,php is empty in 4-5 seconds before the login-box becomes visible.

Maybe it is possible to have a nice loading animation during the time it takes to load the login box?

 

I think this has been fixed. My loader was being hidden on initialization, when it shouldn't have been.

 

In "password-forgotten", if you enter your email-adress and then click on confirm button you get a error massage: "please fill in all required fileds".

So you must click on confirm button twice, you descelct the email field with tab-button or click with the mouse somwhere outside the field.

(IE9)

 

 

 

This is caused by the button submitting before the form validation is complete. Lengthened the timeout. Please recheck. If it is still taking too long, then I'll remove the form field validation altogether and let it validate through ajax instead.

Share this post


Link to post
Share on other sites

@@fulluvscents

 

The login-box

I just tested the first step of checkot.php, the login-box.

 

In IE9 the login-box loads in like 1 second, very good!

 

But in Google Chrome (16.0.912.77) it dosent loads at all the first time.

Waited for like one minute, then refreshed the page.

After i refreshed the page it loads in less then 1 second.

 

In Mozilla, the first time it took like 10 seconds before the log-in box showed up.

I refreshed the page, and the next time it loaded in less then 1 second.

 

I have clean the browser history but dosent get the same error with Mozilla, but in google chrome it dosent shows up at all the first time, but the second it works great.

Maybe something wrong with my Google Chrome

 

 

This is caused by the button submitting before the form validation is complete. Lengthened the timeout. Please recheck. If it is still taking too long, then I'll remove the form field validation altogether and let it validate through ajax instead.

 

Works like a dream!!

 

The pages loads much faster now, and I really like the 50% transparency background behinde the "processing animation".

And you have my vote in "Golden OSCommerce Achievement award" =)

Share this post


Link to post
Share on other sites

@@fulluvscents

 

Just as Martin Luther King, I have a dream, But I dream of the ultimate checkout process for Oscommerce.

You are so close to have created the ultimate OPC!

 

Im not a PHP-guru, but Im well-educated in marketing, costumer psychology and sales, and I recently did a market research of why some swedish Ecommerce sites are so successful and others is unsuccesful.

 

The checkout process is one of the keys to succes, in general for most stores aprox 59% - 75% of all carts are not purchased.

In the research we interviewed costumers and asked them why they dosent finish the purchase.

 

One common answer is that they want to see the shipping and delivery options before they have to creat an account.

 

Is there any possibilty to make the OPC function like my dream checkout?

www.magnusandersson.nu/my_dream_checkout.png

(the picture is to large to post on the forum, and sorry for the swedish - but i writed some english explanations)

 

What do you think?

The biggest change is that you dont have to login before you see all the options.

I

Share this post


Link to post
Share on other sites

@ whoever's comments these were:

 

2, In the password field somethimes I must enter 6 characters to be able to "open" the password-confirmation field.

And somethimes I must enter 8 characters. Strange. :)

3, Even If im sure i entered exactly the same password in both fields, simple like 12345678 requerid filed symbol dosent changes. (on password confirmation field)

 

I think this is fixed. When playing with it, I saw exactly what you're talking about it and from my testing, it seems to be completely resolved now. And I enhanced it a little further by doing a length check on keyup, so that it will change from red to green, vice versa as the length meets or doesn't meet required settings.

 

On the login-box, if I use the password I recived from "forgotten password" I cant get the requred field symbol to change from red to green.

The password is 5 characters long, and it looks like the password needs to be 6 characters long to change the symbol.

If i use the password 123456 it works, but if i use 12345 it dosent. So i cant login with the password I get from "forgotten password".

This has me baffled. I am hoping with the changes I just made to the form validations, that this fix came as part of the bundle.

 

 

@mumme

There is a contribution for shipping quotes in the shopping cart (I don't know if it's been modified for 2.3.1). I also want to be able to give shipping quotes before checkout. But, those aren't suited for the checkout page. They are better suited for the shopping cart, which will save the customer a step in getting those quotes. Eventually, for my own store, I intend on ajaxing the shopping cart, so that it opens in a dialog right on the product page, and also includes a "quick shipping" quote by only entering geographic info. But, one thing at a time.

Share this post


Link to post
Share on other sites

@@fulluvscents

 

I've been reading through this thread and this contribution looks like it is going to be awesome.

We are switching web hosts and I am trying to recreate our old store in 2.3.1. I am really missing the purchase without account option.

The combination of OPC and PWA looks great.

I see you are working on shipping mods. I was wondering if your contribution will be compatible with UPS XML Shipping Rates?

We use UPS Ground shipping in the US only.

I figured I would ask before trying to modify the old PWA.

Thanks so much,

 

Varina

Share this post


Link to post
Share on other sites

I see no reason why it wouldn't work with any existing shipping or payment mod. This was written to work exactly the same as the stock checkout, except in one page instead of three. The general rule on this will be simple.

 

If your add-on does not require you to make changes to the stock checkout, then you will not need to make changes to this checkout.

If it does require changes to stock checkout, then it will also require changes to this checkout.

I don't use UPS, so I don't know the install procedure around it.

 

If the add-on requires changes to the stock checkout, then the unfortunate reality is that they are not going to be as simple on this checkout, but any of it can be done.

Share this post


Link to post
Share on other sites

That is exactly what it means. That was my biggest gripe about the old OPC. If you have to change your mods to fit a script, then the script wasn't written correctly in the first place. I had to rerwite authorize.net (on both my 2.2 and 2.3.1 shops), and I gave up on Paypal altogether.

 

Alrighty, so I got up about 4 hours ago, and haven't gotten crap done. Time to get to work.

Share this post


Link to post
Share on other sites

×