Jump to content
NimaP

One Page Checkout Support

Recommended Posts

Hi All

Shame about this contribution because it would be superb to have this as a permanent fixture in an Osc site, but it looks like there have been many issues with it. I've just run through the install on a test site and although I'm no PHP expert I've installed many osc contributions successfully but have been unable to get this one to work.

 

I just get a blank screen when going to checkout??

 

I've scanned through many of the posts here but cannot find anything referring to it. Has anyone had the same issue or know why I might have this? From what I can see/feel the installation went to plan and the instructions were clear. I'm using Paypal_IPN as the payment mod.

Cheers

Martin

Hi you have a php error, somewhere what screen is blank checkout.php or checkout_shipping.php?

 

Add this code to what ever page is blank

 require('includes/application_top.php');

 

add

 

ini_set('display_errors', 1);
error_reporting(E_ALL);

 

now paste what errors you have here

 

Steve

Share this post


Link to post
Share on other sites

Hey Steve

thanks for your response, much appreciated. These are the errors I'm getting (ouch! it looks a mess) Can I just say one thing too..the site is of adult nature so I've altered the domain name in this post as I wouldn't want to cause any offense to anyone reading this post...but the errors are as is. This is checkout.php

Thanks again

Martin

 

Notice: Undefined variable: payment in /home/sites/jls.com/public_html/includes/classes/onepage_checkout.php on line 1507

 

Notice: Use of undefined constant MODULE_ORDER_TOTAL_DISCOUNT_COUPON_STATUS - assumed 'MODULE_ORDER_TOTAL_DISCOUNT_COUPON_STATUS' in /home/sites/jls.com/public_html/checkout.php on line 50

 

Notice: Use of undefined constant MODULE_ORDER_TOTAL_DISCOUNT_COUPON_STATUS - assumed 'MODULE_ORDER_TOTAL_DISCOUNT_COUPON_STATUS' in /home/sites/jls.com/public_html/includes/classes/onepage_checkout.php on line 149

 

Notice: Use of undefined constant MODULE_ORDER_TOTAL_DISCOUNT_COUPON_STATUS - assumed 'MODULE_ORDER_TOTAL_DISCOUNT_COUPON_STATUS' in /home/sites/jls.com/public_html/includes/classes/onepage_checkout.php on line 212

 

Notice: Use of undefined constant MODULE_ORDER_TOTAL_DISCOUNT_COUPON_STATUS - assumed 'MODULE_ORDER_TOTAL_DISCOUNT_COUPON_STATUS' in /home/sites/jls.com/public_html/includes/classes/onepage_checkout.php on line 224

 

Notice: Use of undefined constant MODULE_ORDER_TOTAL_DISCOUNT_COUPON_STATUS - assumed 'MODULE_ORDER_TOTAL_DISCOUNT_COUPON_STATUS' in /home/sites/jls.com/public_html/includes/classes/onepage_checkout.php on line 269

 

Notice: Use of undefined constant MODULE_PAYMENT_PAYPAL_IPN_TEXT_EMAIL_FOOTER - assumed 'MODULE_PAYMENT_PAYPAL_IPN_TEXT_EMAIL_FOOTER' in /home/sites/jls.com/public_html/includes/modules/payment/paypal_ipn.php on line 25

 

Notice: Undefined variable: pass in /home/sites/jls.com/public_html/includes/modules/order_total/ot_shipping.php on line 41

Edited by martinstan

Share this post


Link to post
Share on other sites

Hey Steve

thanks for your response, much appreciated. These are the errors I'm getting (ouch! it looks a mess) Can I just say one thing too..the site is of adult nature so I've altered the domain name in this post as I wouldn't want to cause any offense to anyone reading this post...but the errors are as is. This is checkout.php

Thanks again

Martin

 

Notice: Undefined variable: payment in /home/sites/jls.com/public_html/includes/classes/onepage_checkout.php on line 1507

 

Notice: Use of undefined constant MODULE_ORDER_TOTAL_DISCOUNT_COUPON_STATUS - assumed 'MODULE_ORDER_TOTAL_DISCOUNT_COUPON_STATUS' in /home/sites/jls.com/public_html/checkout.php on line 50

 

Notice: Use of undefined constant MODULE_ORDER_TOTAL_DISCOUNT_COUPON_STATUS - assumed 'MODULE_ORDER_TOTAL_DISCOUNT_COUPON_STATUS' in /home/sites/jls.com/public_html/includes/classes/onepage_checkout.php on line 149

 

Notice: Use of undefined constant MODULE_ORDER_TOTAL_DISCOUNT_COUPON_STATUS - assumed 'MODULE_ORDER_TOTAL_DISCOUNT_COUPON_STATUS' in /home/sites/jls.com/public_html/includes/classes/onepage_checkout.php on line 212

 

Notice: Use of undefined constant MODULE_ORDER_TOTAL_DISCOUNT_COUPON_STATUS - assumed 'MODULE_ORDER_TOTAL_DISCOUNT_COUPON_STATUS' in /home/sites/jls.com/public_html/includes/classes/onepage_checkout.php on line 224

 

Notice: Use of undefined constant MODULE_ORDER_TOTAL_DISCOUNT_COUPON_STATUS - assumed 'MODULE_ORDER_TOTAL_DISCOUNT_COUPON_STATUS' in /home/sites/jls.com/public_html/includes/classes/onepage_checkout.php on line 269

 

Notice: Use of undefined constant MODULE_PAYMENT_PAYPAL_IPN_TEXT_EMAIL_FOOTER - assumed 'MODULE_PAYMENT_PAYPAL_IPN_TEXT_EMAIL_FOOTER' in /home/sites/jls.com/public_html/includes/modules/payment/paypal_ipn.php on line 25

 

Notice: Undefined variable: pass in /home/sites/jls.com/public_html/includes/modules/order_total/ot_shipping.php on line 41

Hi Martin,

 

Most of them are just warnings not errors, uninstall your payment and shipping modules ans see if page is no longer blank, one of them is causing it to not load fully

 

Steve

Share this post


Link to post
Share on other sites

Hi! fist of all, thanks for this great contribution and everyone who share the support here!! This contribution does save a lot of steps for checkout process and also conbine the "purchase without account" type of checkout option!

 

I have some questions regarding getting this contribution to work with the discount coupon code module. Does any one have an issue of the sub-total and total price is calculated incorrectly? I did some search and couldn't find the answers! The issue is when amount of coupon is applied, the sub-total display the price with discount applied once; then the total price display the price with twice discount applied.

 

Is it something to do with the include/class/onepage_checkout.php function?

 

really appreciate if anyone can share the thoughts!

 

Did this ever get fixed???? I'm trying to figure this out and can't find anywhere in any code that looks like math operations totaling up coupons, taxes, shipping etc. I think it may be in includes/classes/onepage_checkout.php but there are several instances of discount coupons mentioned. Perhaps that's the problem. It does the calculation twice because of the code is in there twice??? Just a stab in the dark... The discount coupons contribution works fine without One Page Checkout enabled but once it's enabled, then it calculates the coupon twice giving the customer double the discount.

Please Help as OPC cant be used until this is fixed.

Rob

 

Are there any programmers out there who can help?

Share this post


Link to post
Share on other sites

Hi Steve,

 

I have that same problem: in my payment options, only Bank Transfer is working. Both Cash on Delivery and Paypal Standard keep saying "loading" when I select them. How can I fix it?

 

Thanks!

 

Maria

 

hi steve,

i upgraded from 1.2 to 1.3 and noticed similar problem as described above. when selecting the paypal standard it says LOADING and does not go eny further.

did you find a solution to this problem?

thanks

Share this post


Link to post
Share on other sites

hi steve,

i upgraded from 1.2 to 1.3 and noticed similar problem as described above. when selecting the paypal standard it says LOADING and does not go eny further.

did you find a solution to this problem?

thanks

Hi,

 

please see this post http://forums.oscommerce.com/topic/333292-one-page-checkout-support/page__view__findpost__p__1503075

 

Steve

Share this post


Link to post
Share on other sites

Hi Steve,

 

I have that same problem: in my payment options, only Bank Transfer is working. Both Cash on Delivery and Paypal Standard keep saying "loading" when I select them. How can I fix it?

 

Thanks!

 

Maria

Hi Maria

 

please see this post http://forums.oscommerce.com/topic/333292-one-page-checkout-support/page__view__findpost__p__1503075

 

Steve

Share this post


Link to post
Share on other sites

One other problem. The one page checkout seems to be periodically leaving tax off the order. It happens on one or two orders then goes back to normal. Any ideas what might cause this?

 

 

Found the cause at least. The VAT is only being added on existing customers accounts where they login. Anyone who creates a new account or checkouts without creating an account via the one page checkout does not get the VAT added.

Share this post


Link to post
Share on other sites

Found the cause at least. The VAT is only being added on existing customers accounts where they login. Anyone who creates a new account or checkouts without creating an account via the one page checkout does not get the VAT added.

 

 

aah that explains why no ones order shows the vat (tax) amount in my shop - the figures come correct at the end - they show net in the order total.

 

I thought i was the only one who was having this problem

any one got a fix its classes folder i think ?

Share this post


Link to post
Share on other sites

Hi all

Thanks for the on going support with this contribution. I think I may be missing something here (literally)! Am I using a different version of Oscommerce to others because I don't have the file: includes/languages/english/modules/payment/paypal_standard.php in my original Osc installation?

 

The reason I ask is because it is referred to in the module install and it's thrown up these in my payment modules:

 

Warning: main(/home/sites/public_html/includes/languages/english/modules/payment/paypal_standard.php) [function.main]: failed to open stream: No such file or directory in /home/sites/public_html/admin/modules.php on line 129

 

Warning: main(/home/sites/public_html/includes/languages/english/modules/payment/paypal_standard.php) [function.main]: failed to open stream: No such file or directory in /home/sites/public_html/admin/modules.php on line 129

 

Warning: main() [function.include]: Failed opening '/home/public_html/includes/languages/english/modules/payment/paypal_standard.php' for inclusion (include_path='.:/usr/share/pear') in /home/sites/public_html/admin/modules.php on line 129

 

thanks

Martin

Share this post


Link to post
Share on other sites

Hi all

Thanks for the on going support with this contribution. I think I may be missing something here (literally)! Am I using a different version of Oscommerce to others because I don't have the file: includes/languages/english/modules/payment/paypal_standard.php in my original Osc installation?

 

The reason I ask is because it is referred to in the module install and it's thrown up these in my payment modules:

 

Warning: main(/home/sites/public_html/includes/languages/english/modules/payment/paypal_standard.php) [function.main]: failed to open stream: No such file or directory in /home/sites/public_html/admin/modules.php on line 129

 

Warning: main(/home/sites/public_html/includes/languages/english/modules/payment/paypal_standard.php) [function.main]: failed to open stream: No such file or directory in /home/sites/public_html/admin/modules.php on line 129

 

Warning: main() [function.include]: Failed opening '/home/public_html/includes/languages/english/modules/payment/paypal_standard.php' for inclusion (include_path='.:/usr/share/pear') in /home/sites/public_html/admin/modules.php on line 129

 

thanks

Martin

Hi Martin,

 

Simply download paypal standard from contributions and upload the language file

 

or create the file /includes/languages/english/modules/payment/paypal_standard.php

 

and add this code in it

<?php
/*
 $Id: paypal_standard.php 1778 2008-01-09 23:37:44Z hpdl $

 Digistore v4.0,  Open Source E-Commerce Solutions
 http://www.digistore.co.nz

 Copyright (c) 2008 osCommerce

 Released under the GNU General Public License
*/

 define('MODULE_PAYMENT_PAYPAL_STANDARD_TEXT_TITLE', 'PayPal Website Payments Standard');
 define('MODULE_PAYMENT_PAYPAL_STANDARD_TEXT_PUBLIC_TITLE', 'PayPal (including Credit Cards and Debit Cards)');
 define('MODULE_PAYMENT_PAYPAL_STANDARD_TEXT_DESCRIPTION', '<img src="images/icon_popup.gif" border="0"> <a href="https://www.paypal.com/mrb/pal=PS2X9Q773CKG4" target="_blank" style="text-decoration: underline; font-weight: bold;">Visit PayPal Website</a> <a href="javascript:toggleDivBlock(\'paypalStdInfo\');">(info)</a><span id="paypalStdInfo" style="display: none;"><br><i>Using the above link to signup at PayPal grants osCommerce a small financial bonus for referring a customer.</i></span>');
?>

 

Steve

Share this post


Link to post
Share on other sites

aah that explains why no ones order shows the vat (tax) amount in my shop - the figures come correct at the end - they show net in the order total.

 

I thought i was the only one who was having this problem

any one got a fix its classes folder i think ?

Hi

 

This is due to display prices with tax set to false, if they log in they see tax, so in admin>configuration>My Store

set

Display Prices with Tax to true

 

failing that in includes/classes/onepage_checkout.php

find

 if (DISPLAY_PRICE_WITH_TAX == 'false'){
       $taxCountryID = 0;
       $taxZoneID = 0;

 

change it to

 if (DISPLAY_PRICE_WITH_TAX == 'false'){
      $taxCountryID = $onepage['delivery']['country_id'];
     $taxZoneID = $onepage['delivery']['zone_id'];

 

Steve

Share this post


Link to post
Share on other sites

hi

the store admin is set to true

 

and this

 

if (DISPLAY_PRICE_WITH_TAX == 'false'){

$taxCountryID = 0;

$taxZoneID = 0;

 

doesn't exist in

 

includes/classes/onepage_checkout.php

Edited by fernyburn

Share this post


Link to post
Share on other sites
if ($cart->get_content_type() == 'virtual' && is_numeric($onepage['billing']['country_id'])) {

$taxCountryID = $onepage['billing']['country_id'];

$taxZoneID = $onepage['billing']['zone_id'];

}elseif (is_numeric($onepage['delivery']['country_id'])){

$taxCountryID = $onepage['delivery']['country_id'];

$taxZoneID = $onepage['delivery']['zone_id'];

}elseif (!tep_session_is_registered('customer_id')) {

if (DISPLAY_PRICE_WITH_TAX == 'false'){

$taxCountryID = 0;

$taxZoneID = 0;

}else{

 

this is in version 1.2 but missing in 1.3 ???

Share this post


Link to post
Share on other sites

hi

the store admin is set to true

 

and this

 

 

 

doesn't exist in

 

includes/classes/onepage_checkout.php

Your quite correct i was looking at 1.2

 

this is the code for the tax in 1.3 man they added a lot to it, it is hard to figure out where the normal tax is being applied in includes/classes/onepage_checkout.php compared to 1.2

 

        if (DISPLAY_PRICE_WITH_TAX == 'true'){
         $order->info['tax'] += $shown_price - ($shown_price / (($products_tax < 10) ? "1.0" . str_replace('.', '', $products_tax) : "1." . str_replace('.', '', $products_tax)));
         if (isset($order->info['tax_groups']["$products_tax_description"])) {
           $order->info['tax_groups']["$products_tax_description"] += $shown_price - ($shown_price / (($products_tax < 10) ? "1.0" . str_replace('.', '', $products_tax) : "1." . str_replace('.', '', $products_tax)));
         }else{
           $order->info['tax_groups']["$products_tax_description"] = $shown_price - ($shown_price / (($products_tax < 10) ? "1.0" . str_replace('.', '', $products_tax) : "1." . str_replace('.', '', $products_tax)));
         }
       }else{
         $order->info['tax'] += ($products_tax / 100) * $shown_price;
         if (isset($order->info['tax_groups']["$products_tax_description"])) {
           $order->info['tax_groups']["$products_tax_description"] += ($products_tax / 100) * $shown_price;
         }else{
           $order->info['tax_groups']["$products_tax_description"] = ($products_tax / 100) * $shown_price;
         }
       }
       //echo $shown_price."\n";
     }

 

Steve

Share this post


Link to post
Share on other sites

this is in version 1.2 but missing in 1.3 ???

 

 

when i add this into the space in 1.3 it works properly for the tax being shown - so leaving it out creats problems ?

Share this post


Link to post
Share on other sites

when i add this into the space in 1.3 it works properly for the tax being shown - so leaving it out creats problems ?

im not sure they have changed big time how the tax is done in 1.3 in includes/classes/onepage_checkout.php

 

if you added it and it works fine then go with it

 

Steve

Share this post


Link to post
Share on other sites
Hi Martin,

 

Simply download paypal standard from contributions and upload the language file

 

or create the file /includes/languages/english/modules/payment/paypal_standard.php

 

Steve, thanks for your tireless support. I'm a little confused as to which paypal module I should be using for this contribution. I've always assumed that Paypal IPN is the preferred module but should I be using Paypal standard in actual fact?

Thanks

Martin

Share this post


Link to post
Share on other sites

Steve, thanks for your tireless support. I'm a little confused as to which paypal module I should be using for this contribution. I've always assumed that Paypal IPN is the preferred module but should I be using Paypal standard in actual fact?

Thanks

Martin

Hi Martin,

 

That is up to you paypal ipn is the old version now and paypal standard is the newer version of ipn, they both do a similar thing, if ipn works and your happy stay with ippn

 

Steve

Edited by steve_s

Share this post


Link to post
Share on other sites

Hi Steve

I have a website that is using an older version of one page checkout

how do I proceed if I would like to update to the new one?

replace all the files if from version 1.0 and above and run the sql a few pages back i posted the sql with the syntax error bug fixed, if a real older version follow install best you can on replacing code

 

Steve

Share this post


Link to post
Share on other sites

 

 

Hi Steve,

I have that same problem (I have several payment methods and the only ones that get stuck with "setting payment method" are paypal_ipn and paypal_standard, it works in opera but it doesn't on firefox 3.5 and IE 8) and I've already looked that post and when I apply those changes it gives me this error:

 

Fatal error: Cannot use string offset as an array in /usr/www/users/metalmex/intelcompras/includes/checkout/payment_method.php on line 66

 

any help would be apreciated.

Thanks

Share this post


Link to post
Share on other sites

Hi Steve,

I have that same problem (I have several payment methods and the only ones that get stuck with "setting payment method" are paypal_ipn and paypal_standard, it works in opera but it doesn't on firefox 3.5 and IE 8) and I've already looked that post and when I apply those changes it gives me this error:

 

Fatal error: Cannot use string offset as an array in /usr/www/users/metalmex/intelcompras/includes/checkout/payment_method.php on line 66

 

any help would be apreciated.

Thanks

Hi

 

did you upload the payment files that came with one page checkout if so inform it webexperts.com using email to report bugs to in install guide tell them you made the changes that post suggested and the browsers it doesnt work with

 

Steve

Share this post


Link to post
Share on other sites

In the latest version 1.3 I've found 26 instances of the site name ShedsForLessDirect in hardcoded messages in the following files: checkout.php and includes\checkout\checkout.js

I've replaced 'ShedsForLessDirect' in my files with 'IT Support'.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×