20 replies [Last post]
mortendk's picture
Offline
Internationalizationizer
Joined: 04/07/2008
Juice: 32
Was this information Helpful?

Okay i got this wonderfull messages for my config of the shipping:
"Javascript must be enabled to view the order total preview."
but ehem i got my javasctipt on (and the payment options work just as its supposed to do - with js call n all)

so ehem i guess theres an error somewhere else - but this error msg reminds me of "theres an error somewhere between line 2 and 3231424" Eye-wink

mortendk's picture
Offline
Internationalizationizer
Joined: 04/07/2008
Juice: 32
Re: error: Javascript must be enabled to view the order total pr

figured this out by myself...
Dont (DONT!) have any js errors anywhere in you site - it will screw with the ajax calls

/morten.dk

fredklopper's picture
Offline
Joined: 01/20/2008
Juice: 28
Same problem

Hi there,

I'm facing the same problem since I've upgraded to 1.4.

I don't see any Javascript errors and I don't realy know where to start. Can you point me in the right direction?

With best regards,

Fred

TR
TR's picture
Online
Bug FinderFAQ ModeratorGetting busy with the Ubercode.
Joined: 11/05/2007
Juice: 3424
Re: Same problem

Can you post a URL so we can take a look?

<tr>.
fredklopper's picture
Offline
Joined: 01/20/2008
Juice: 28
Yes you can!

62.163.64.160/lambo

Thanks in advance!

TR
TR's picture
Online
Bug FinderFAQ ModeratorGetting busy with the Ubercode.
Joined: 11/05/2007
Juice: 3424
Re: Yes you can!

Yes, there's a JavaScript error on that page. What version of Drupal and Ubercart are you using? As far as I know, s_street2 has *never* appeared in uc_taxes.js - have you modified or patched the taxes module? What contributed modules do you have installed, could one of them be the culprit? The uc_taxes module had some changes between UC 1.3 and UC 1.4, so perhaps one of your contributed modules is misbehaving with UC 1.4 ...

s_street2 has no properties
getTax()uc_taxes.js (line 79)
(no name)()uc_taxes.js (line 13)
e()jquery.js (line 11)
e()jquery.js (line 11)
e([function(), function(), function(), 13 more...], function(), undefined)jquery.js (line 11)
e()jquery.js (line 11)
[Break on this error] + '";s:16:"delivery_street2";s:' + s_street2.length + ':"' + encodeURICompon...
<tr>.
fredklopper's picture
Offline
Joined: 01/20/2008
Juice: 28
Re: Re: Yes you can!

Thanks for your very quick reply.

I'm using Drupal 5.9 and the latest Ubercart release (1.4, just out of the box) and didn't modify or patch the taxes module.

There is one contributed module I'm using: uc_legalaspects.

With best regards,

Fred

TR
TR's picture
Online
Bug FinderFAQ ModeratorGetting busy with the Ubercode.
Joined: 11/05/2007
Juice: 3424
Re: Re: Re: Yes you can!

Looks like it's working on your site now? I see s_street2 *does* now show up in the 1.4 release of uc_taxes.js. But it looks like you've removed the street2 textfield from your delivery and billing address forms? If the street2 textfield doesn't exist, then the s_street2 variable will be null and you'll get that JavaScript error. If the street2 textfield is simply empty, that shouldn't happen.

<tr>.
TR
TR's picture
Online
Bug FinderFAQ ModeratorGetting busy with the Ubercode.
Joined: 11/05/2007
Juice: 3424
Re: Re: Re: Re: Yes you can!

Ah, I think I see the problem. If you turn off the "Street address 2" field at admin/store/settings/checkout/edit/fields then the JavaScript will fail like you're seeing. This seems to be a bug in the 1.4 version of uc_taxes.js, which should be testing for the existence of the field before using it.

<tr>.
fredklopper's picture
Offline
Joined: 01/20/2008
Juice: 28
Re: Re: Re: Re: Re: Yes you can!

Thanks a lot for pointing me in the right direction! It's a bug. I have disabled Street address 2 and it should be tested like you said.

I wasn't able to see where it went wrong because my Firebug was misbehaving. Sad

With best regards!

Ryan's picture
Offline
Joined: 08/07/2007
Juice: 15438
Re: Re: Re: Re: Re: Re: Yes you can!

TR... you rock. Thanks for figuring this one out! We'll be getting this into a 1.5 release with a few other fixes by the end of the week.

enlighten_me's picture
Offline
Joined: 04/25/2008
Juice: 83
Re: Re: Re: Re: Re: Re: Re: Yes you can!

I'm getting this error too. Running ubercart 1.5. The Web Developer toolbar is telling me jquery.js is giving this error: ret[ret.length - 1] is undefined

I'm not sure how to trace the error. I also noticed the credit card text fields aren't showing by default - the radio has to be selected to Paypal and back for the fields to show up - is this related?

www.magnaflowstop.com

Thanks in advance.

enlighten_me's picture
Offline
Joined: 04/25/2008
Juice: 83
Re: Re: Re: Re: Re: Re: Re: Re: Yes you can!

Resolved it. The jquery_update module has a buggy jquery.js file. I removed the module and put back the original jquery.js into /misc

gwrtheyrn's picture
Offline
Joined: 03/14/2009
Juice: 2
Re: Re: Re: Re: Re: Re: Re: Re: Re: Yes you can!

thank you, enlighten_me, that resolved my problem too. i just renamed jquery.js.old to jquery.js, and the shipping quotes module works again.

romamark78's picture
Offline
Joined: 05/26/2009
Juice: 7
i'm having this same error

I'm having this same error with my installation, i've tried re-installing the jquery plugin or resetting to an older version of the file. does anyone have any idea on how to set the credit card text fields to be a permanently open window?
or are there any other fixes for this problem someone can suggest?

dave_the_brave's picture
Offline
Joined: 08/07/2008
Juice: 79
Experiencing the same thing

Hey guys

I'm having the same problem, but address 2 is enabled. The only additional module I have for UC is discounts. The staging site is at http://tcw.southernwoodexpress.com. One product - the event on the home page.

I'd appreciate if you can tell me if there is an error on the page. I can't see it. Tested so far in Safari and FF2.

Thanks
Dave

Ryan's picture
Offline
Joined: 08/07/2007
Juice: 15438
Re: Experiencing the same thing

Hey Dave, are you running the 1.5 version of UC?

dave_the_brave's picture
Offline
Joined: 08/07/2008
Juice: 79
I hadn't

Sticking out tongue

Now I am and it's fine... I was wondering about it because I had default address set up, so wasn't sure how 1.5 had changed the preview code.

Thanks!
D

light-blue-pdx's picture
Offline
Joined: 04/25/2009
Juice: 4
Re: error: Javascript must be enabled to view the order total pr

in my case, this was due to jstools for drupal 5. It was easy to fix. Locate your theme directory (mine was drupal/sites/mysite/themes/custom/zen/mysite), open page.tpl.php, save it as page-cart-checkout.tpl.php and change

<?php
print $scripts;
?>

TO

<?php
$scripts
=str_replace('jquery.js','jquery.js.old',$scripts); print $scripts; //dpm($scripts);
?>

That assumes you renamed the default drupal jquery.js to jquery.js.old. It allows you to use the newer jquery.js on all pages but the cart checkout page.

cjboranp's picture
Offline
Joined: 05/21/2009
Juice: 10
Partially working, but partially not.

Working on drupal 5 I have encountered the same "ret is undefined". I have a custom gateway (which is not paypal) setup my credit card encryption and can checkout in test mode.

In the Payment Methods pane, Jquery will not pop up manually if there is only 1 payment method. I had to remove the default selection to at least allow people to click on the 1 payment method to make credit card payments show up. Similar to this, when i switch countries from US to Canada (Yes I'm Canadian... please don't shoot) jquery does not dynamically flip the states to the provinces and vice versa.

However, after logging a payment and ubercart stores the address, the "saved addresses" box in the "billing information" pane populates correctly including the change for country.

Any ideas?

martinmenge's picture
Offline
Joined: 09/30/2010
Juice: 30
Order Preview error in Safari and Chrome, not FF

I get the "Javascript must be enabled to view the order total preview." error in UC 2 with Drupal 6.20. Any suggestions?