Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

One Page Checkout Support


Guest

Recommended Posts

Hi Steve cannot search the entire topic so I dont know if you already answered to this, but after I checkout using PayPal, then when the transaction is complete and I click on "Return to store", it takes me back to the checkout page, instead of taking me to the main store catalog page...do you know how I can fix this? let me know...thank you

Hi

 

What paypal are you using, look in admin-modules-payment and see if there is a return link you can specifiy

 

Steve

Link to comment
Share on other sites

Hi all,

 

I've got two stores, similar but with the following minor differences:

 

Store 1: RC2a ... Simple Template System v4.5.8 installed ... store is located in site root

Store 2: MS2.2 ... Columns and header hard coded ... store is located in sub folder /store/

 

Store 1 has been running One Page Checkout v1.05 for about 5 months, then later upgraded to v1.08, again with no problems.

 

I've just installed OPC v1.09 on Store 2 and its not working. I've also tried downgrading to v1.08, but the same problem exists as follows:

 

Once all billing details have been completed, pressing the 'Continue' button at the bottom of the checkout screen moves onto the "Processing order, please wait..." screen for a couple of seconds, then goes back to the checkout screen again and blanks out all of the details.

 

I can see the "Processing order" screen attempts to post the form with hidden values as below:

 

<form name="redirectForm" action="XXXXXXX/store/checkout_process.php?osCsid=0mjol444f5inivkk9r6lh3cbq4" method="POST">

<input type="image" src="includes/languages/english/images/buttons/button_continue.gif" border="0" alt="IMAGE_CONTINUE" title=" IMAGE_CONTINUE " style="display:none;"><input type="hidden" name="action" value="process"><input type="hidden" name="3084" value="1">

...(code removed)... <input type="hidden" name="formUrl"><script>

redirectForm.submit();

</script></form>

 

Can anyone see why it is failing and not giving an error? If anybody is able to advise, here is a link to test (remove the two instances of XXX for the correct URL):

 

http://www.ajXXXcanvasXXXprints.co.uk/store/test-product-p-3084.html

 

Please add the test product to the cart and go straight to checkout. Use the "cheque/postal order" payment method to complete the order. Please note that I'm using a shared SSL host, but please ignore this fact as it is identical to my first store which works fine.

 

Any help or pointers of where I need to look would be much appreciated !

 

Cheers

 

Andy

Hi Andy

 

in includes/classes/onepage_checkout.php

find this code and amend it as it says

	function setPaymentMethod($method){
	global $payment_modules, $language, $order, $cart, $payment, $onepage;
	/* Comment IF statement below for oscommerce versions before MS2.2 RC2a */
	if (tep_session_is_registered('payment') && tep_not_null($payment) && $payment != $method){
		$GLOBALS[$payment]->selection();
	}

	if (!tep_session_is_registered('payment')){
		tep_session_register('payment');
	}
	$payment = $method;
	$onepage['info']['payment_method'] = $method;

	$order->info['payment_method'] = $GLOBALS[$payment]->title;

	/* Comment line below for oscommerce versions before MS2.2 RC2a */
	$confirmation = $GLOBALS[$payment]->confirmation();

	/* Uncomment line below for oscommerce versions before MS2.2 RC2a */
	//$confirmation = $GLOBALS[$payment]->selection();

Link to comment
Share on other sites

Thanks Steve

What I meant to ask you was if there is a way to have just United States as country available for billing and shipping address and therefore a drop down menu in the state field.

I have this setup in the registration form to create customers account, but I dont know how to implement the same thing in the checkout file...

Hi

 

in includes/languages/english.php find line with

DEFAULT_COUNTRY

 

now change that whole line to

define ('DEFAULT_COUNTRY', STORE_COUNTRY);

 

This will use the country you have said your store is in, in admin-configuration-My store

 

Steve

Link to comment
Share on other sites

Hi Andy

 

in includes/classes/onepage_checkout.php

find this code and amend it as it says

	function setPaymentMethod($method){
	global $payment_modules, $language, $order, $cart, $payment, $onepage;
	/* Comment IF statement below for oscommerce versions before MS2.2 RC2a */
	if (tep_session_is_registered('payment') && tep_not_null($payment) && $payment != $method){
		$GLOBALS[$payment]->selection();
	}

	if (!tep_session_is_registered('payment')){
		tep_session_register('payment');
	}
	$payment = $method;
	$onepage['info']['payment_method'] = $method;

	$order->info['payment_method'] = $GLOBALS[$payment]->title;

	/* Comment line below for oscommerce versions before MS2.2 RC2a */
	$confirmation = $GLOBALS[$payment]->confirmation();

	/* Uncomment line below for oscommerce versions before MS2.2 RC2a */
	//$confirmation = $GLOBALS[$payment]->selection();

 

Hi Steve,

 

Thanks for the quick response ! Unfortunately though, my problem still exists after commenting/uncommenting the various lines.

 

Have you any idea what else might be causing it?

 

Cheers

 

Andy

Link to comment
Share on other sites

Hi Steve,

 

Thanks for the quick response ! Unfortunately though, my problem still exists after commenting/uncommenting the various lines.

 

Have you any idea what else might be causing it?

 

Cheers

 

Andy

Hi Andy

 

Have you added the code to checkout_process.php also check one page setting in configuration for create account you should have 3 options i

 

Steve

Link to comment
Share on other sites

Hi Andy

 

Have you added the code to checkout_process.php also check one page setting in configuration for create account you should have 3 options i

 

Steve

 

Yes, I've added the code to checkout_process.php twice now and even tried the file from my working RC2a install as a test. I get 3 options for the create account, of which I've tried it with optional and create.

 

In every instance, I get thrown back to a blank checkout page when attempting to confirm the checkout. My server error logs show all of the GET and POST requests, but no errors. Do you have any idea how I can debug this?

 

Cheers

 

Andy

Link to comment
Share on other sites

Yes, I've added the code to checkout_process.php twice now and even tried the file from my working RC2a install as a test. I get 3 options for the create account, of which I've tried it with optional and create.

 

In every instance, I get thrown back to a blank checkout page when attempting to confirm the checkout. My server error logs show all of the GET and POST requests, but no errors. Do you have any idea how I can debug this?

 

Cheers

 

Andy

Hi,

 

Try setting require login to true, now try a test order and see what happens if it works, then its something wrong on the create account

 

Steve

Link to comment
Share on other sites

Seeing as the shopping cart is shown on the checkout.php page, I figured I would like the user not to have to go to the shopping cart before going to checkout (I also would like it so that they did not simply stay on the same page, as setting Display Cart After Adding Product to false in Admin-Configuration-My Page currently does).

 

So I found this simple change worked a treat on my store. Thans to Jan Zonjee who helped me figure out this change.

 

You want to edit catalog/includes/application_top.php - around line 320- in the following way:

 

Thanks Jan Zonjee - I edited the following, changing the second $goto value to FILENAME_CHECKOUT_SHIPPING. So it went from this:

 

   if (DISPLAY_CART == 'true') {
     $goto =  FILENAME_SHOPPING_CART;
     $parameters = array('action', 'cPath', 'products_id', 'pid');
  } else {
   $goto = basename($PHP_SELF);
    if ($HTTP_GET_VARS['action'] == 'buy_now') {
       $parameters = array('action', 'pid', 'products_id');
    } else {
       $parameters = array('action', 'pid');
    }
   }

 

To this:

 

 if (DISPLAY_CART == 'true') {
     $goto =  FILENAME_SHOPPING_CART;
     $parameters = array('action', 'cPath', 'products_id', 'pid');
   } else {
   $goto = FILENAME_CHECKOUT_SHIPPING;
   if ($HTTP_GET_VARS['action'] == 'buy_now') {
    $parameters = array('action', 'pid', 'products_id');
    } else {
    $parameters = array('action', 'pid');
 }
 }

 

It seems to work a treat on my store, which uses a shared SSL certificate. I have the One page Checkout modification installed, so this in turn redirects me to a checkout.php page with all the checkout content on it. Excellent. I hope it works for others too.

 

Thanks again for the key Jan!

 

 

I hope it helps anyone striving to get the smoothest checkout available!

 

NB: For this method to work the Display Shopping Cart after Adding Product option on the admin configuration page has to be set to false!

Link to comment
Share on other sites

Ooh also does anyone know why some of my prices are coming up as

 

£144.00

 

while some are displayed normally i.e.

 

£40.00
?

 

The erroneous ones are the Sub-total and Total values in the shopping cart box - and all of the values in the bottom "Add comments to your order" box.

 

I would have thought it a simple problem but the individual prices in the shopping cart box look fine! Any help would be much appreciated.

 

PS: This is a great contribution so thanks very much!

Link to comment
Share on other sites

Is that on trying to create an account or user already loged in, if you upgraded you will neeed to remove old sql for create account and replace with new sql from install see previous page for this

 

Steve

 

That is only when trying to create an account or checking out with no account. This is a completely fresh install.

 

Do I need to also have purchase without account installed for this contribution to work correctly?

 

I will check the database to make sure all the columns were correctly inserted and get back.

 

Thanks!

Link to comment
Share on other sites

Hi

 

in includes/languages/english.php find line with

DEFAULT_COUNTRY

 

now change that whole line to

define ('DEFAULT_COUNTRY', STORE_COUNTRY);

 

This will use the country you have said your store is in, in admin-configuration-My store

 

Steve

 

Hi Steve

thanks...but I cannot find that line in my eglish.php file...tried to add the line anyway...no luck...

any other way I could manage to force country to be just United States in the checkout billing and shpping forms?

let me know

Link to comment
Share on other sites

To move them down you add <tr> before and </tr> after the code

To add a space between them look for </td><td>

then add <td>  </td> between </td><td>

 

Steve

 

Thanks for the reply Steve. Can you show me exactly what you mean as I am lost. :(

Link to comment
Share on other sites

Hi,

 

Try setting require login to true, now try a test order and see what happens if it works, then its something wrong on the create account

 

Steve

 

I've tried this too, but unfortunately it doesn't work. However, the checkout does complete and move to checkout_success if I log in using a previously created account. Again, if I manually create an account, then go to checkout, it also works with no problems.

 

It does appear to be related to creating the account using One Page Checkout, but I'm not sure where to look ... ?

 

Cheers

 

Andy

Link to comment
Share on other sites

Hi

 

I've just found that my site was hacked over the weekend, So I installed the contribution, sitemoitor. When running the Manually Check for Hacked Files it includes two files from this contribution. Now I'm no expert, but I know many of you out there are. The files are

 

includes/checkout/one page checkout/paypal_standard.php

includes/modules/payment/paypal_standard.php

 

I feel the hack has been caused by the host company as I'm able to sftp-download my configure.php file even though my page is set to 400 (read only). Just glade it's a test domain.

 

But just in case are these's just normal files or is it something else to worry about? It does say in the Sitemonitor contribution that some files are needed.

 

Regards. Dragondust

Link to comment
Share on other sites

Hi

 

I've just found that my site was hacked over the weekend, So I installed the contribution, sitemoitor. When running the Manually Check for Hacked Files it includes two files from this contribution. Now I'm no expert, but I know many of you out there are. The files are

 

includes/checkout/one page checkout/paypal_standard.php

includes/modules/payment/paypal_standard.php

 

I feel the hack has been caused by the host company as I'm able to sftp-download my configure.php file even though my page is set to 400 (read only). Just glade it's a test domain.

 

But just in case are these's just normal files or is it something else to worry about? It does say in the Sitemonitor contribution that some files are needed.

 

Regards. Dragondust

 

Hi

 

download what ever version of OPC you are using and replace them 2 files 2 be safe

 

Steve

Link to comment
Share on other sites

I've tried this too, but unfortunately it doesn't work. However, the checkout does complete and move to checkout_success if I log in using a previously created account. Again, if I manually create an account, then go to checkout, it also works with no problems.

 

It does appear to be related to creating the account using One Page Checkout, but I'm not sure where to look ... ?

 

Cheers

 

Andy

 

I have that same exact issue. Everything works fine as long as the customer already has an account. Checking out without an account or trying to create an account while checking out does not work.

 

I saw that Steve had the same question about a month ago. Did Steve ever get the create account issue resolved?

 

Kean

Link to comment
Share on other sites

What is the deal with Purchase Without Account and One Page Checkout? I've seen a lot of posts mentioning the former but I'm confused.

 

Surely, one does not need to have it installed. I mean, the checkout.php within One Page Checkout serves as its own version of Purchase Without Account, doesn't it? You can log in there...you can fill in your details and choose to create an account there...or...you can fill in your details and not create an account, right?

 

But, what if you do have PWA installed? What's the conflict, if any? If you're using One Page Checkout....that checkout bypasses the normal login.php which contains the options to log in, create account or PWA. Right? So, as you can see, I'm confused as to why PWA has any relevance with regard to One Page Checkout.

 

I don't have PWA on my test site but I do have PWA installed on my live site, so...I need to know more about it before I attempt to switch over to One Page Checkout. Couldn't I just get rid of PWA entirely and use One Page Checkout as a purchase-without-account option?

 

- Andrea

Link to comment
Share on other sites

I have that same exact issue. Everything works fine as long as the customer already has an account. Checking out without an account or trying to create an account while checking out does not work.

 

I saw that Steve had the same question about a month ago. Did Steve ever get the create account issue resolved?

 

Kean

Hi Kean

 

Please see this thread

 

http://www.oscommerce.com/forums/topic/333292-one-page-checkout-support/page__view__findpost__p__1459392

 

Steve

Link to comment
Share on other sites

What is the deal with Purchase Without Account and One Page Checkout? I've seen a lot of posts mentioning the former but I'm confused.

 

Surely, one does not need to have it installed. I mean, the checkout.php within One Page Checkout serves as its own version of Purchase Without Account, doesn't it? You can log in there...you can fill in your details and choose to create an account there...or...you can fill in your details and not create an account, right?

 

But, what if you do have PWA installed? What's the conflict, if any? If you're using One Page Checkout....that checkout bypasses the normal login.php which contains the options to log in, create account or PWA. Right? So, as you can see, I'm confused as to why PWA has any relevance with regard to One Page Checkout.

 

I don't have PWA on my test site but I do have PWA installed on my live site, so...I need to know more about it before I attempt to switch over to One Page Checkout. Couldn't I just get rid of PWA entirely and use One Page Checkout as a purchase-without-account option?

 

- Andrea

Hi

 

You can use both, one page checkout creates an account hence password field

 

you set require login to be true for pwa to be used

 

Steve

Link to comment
Share on other sites

I have a problem :-(.

 

In testing creating a new account during the order process - it was discovered the account created did not get assigned with the password the user inputted - but instead with a randomly generated one. This was when the Account Creation setting was optional (I think!)

 

I have since changed this to setting to required (as this is best for my store). However, now when you go through checkout (with a password e.t.c) entered, an order record is created (and order e-mail sent to customer), but an account is not created (nor is an account created email sent to the customer).

 

I do not know where the source of this error could be coming from so I have held back posting any code. I hope you can help!

 

PS: - Still having trouble with currency symbols - tried using "<?php header("Content-Type: text/html; charset=UTF-8\n");" at the start of the checkout.php page but it did nothing. I am also unsure as to where I would edit £ signs to & # 163; as discussed on Page 3 - plus apparently this solution would result in emails sent with the £ code as opposed to displaying £ signs. Only the order total module £ signs seem to be displaying incorrectly.

 

Thanks in advance

Link to comment
Share on other sites

I have a problem

 

If user changes number of the products, for exemple, 1 to 10, and then he has click in update, prices update ok, but shipping not update.

 

Please help me.Regards

Hi Report that bug to itwebexperts email is in install instructions file, also check their demo does same thing before reporting it

 

Steve

Link to comment
Share on other sites

I have a problem :-(.

 

In testing creating a new account during the order process - it was discovered the account created did not get assigned with the password the user inputted - but instead with a randomly generated one. This was when the Account Creation setting was optional (I think!)

 

I have since changed this to setting to required (as this is best for my store). However, now when you go through checkout (with a password e.t.c) entered, an order record is created (and order e-mail sent to customer), but an account is not created (nor is an account created email sent to the customer).

 

I do not know where the source of this error could be coming from so I have held back posting any code. I hope you can help!

 

PS: - Still having trouble with currency symbols - tried using "<?php header("Content-Type: text/html; charset=UTF-8\n");" at the start of the checkout.php page but it did nothing. I am also unsure as to where I would edit £ signs to & # 163; as discussed on Page 3 - plus apparently this solution would result in emails sent with the £ code as opposed to displaying £ signs. Only the order total module £ signs seem to be displaying incorrectly.

 

Thanks in advance

 

Hi

 

1 what payment method are you using if they dont return back to site i dont think the create account function is invoked

 

2 currency will display as £ using utf8 code if they can display html in email

 

3 edit £ signs to & # 163 in admin>localasiation>currencies

 

edit the symbol to code

 

Steve

Link to comment
Share on other sites

Thanks for the response. I changed the code (although to & # 163; - don't know if that semi colon will be important for everyone) an the £ signs are displaying fine so thanks for that.

 

I am currently trying to checkout using a Check/Postal Order module - which basically directs straight to checkout_success after confirmation. This happens completely regularly.

 

I have checked what happens with each of the different Account Creation options selected (in each case I entered a password in the password fields). For required, as said, the order is made successfully, but no account is created. For create, the order is made successfully and a new account is created - although with a random password and not the one input by the customer. For optional - no account is created.

 

I just can't figure it out!Hopefully it's something simple.

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