Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Ulrich Wagner Gade Ebsen 127 posts 277 karma points
    Dec 23, 2012 @ 02:05
    Ulrich Wagner Gade Ebsen
    0

    Javascript API & Safari

    Hi,

    I'm having some serious issues realed to the javascript API and Safari. It seems that on some versions of Safari, Tea Commerce cannot write it's cookie. My client are getting a handfulle of calls every week from customers that cannot buy from his site - and they are all using Safari. I have tried on my iphone, ipad, mac mini and a couple of PC's... one my iphone it fails... the same error is found on the Tea Commerce demo site - http://starterkit.teacommerce.net/en/frontpage/ - so it's a consitant error/issue?!

    The site I'm having issues with is http://greed.dk. Anyone seen this error before or have a solution?

    Thanks
    Ulrich Ebsen

  • Anders Burla 2560 posts 8256 karma points
    Dec 27, 2012 @ 10:39
    Anders Burla
    0

    Hi Ulrich

    What steps should we do to regenerate the error?

    Kind regards
    Anders

  • Haytse 3 posts 23 karma points
    Feb 04, 2013 @ 09:51
    Haytse
    0

    I have been having the same problem with a website on which we used Tea Commerce. When you add an item to the cart in Safari on iPad everything seems normal. When you navigate to another product and add it to your cart the price shown in the mini-cart is the price of the last item you added. When you go to your cart it shows both products. When you then delete all the products from your cart and go to another page your cart magically contains another product.

    We tested this on an iPad 3 and an iPad Mini, both exhibit the same problem. If you access the shop via google chrome for iPad the cart works just as it would on a PC. I tried one final thing and that is clearing all the cookies on my iPad 3 (there were a lot of them). After I did that the cart functions as it should. Of course, other clients can have the same problem and would probably not order anything when they encounter this problem.

    We started with the Tea Commerce starter kit as our base site.

    Is it a known problem that Safari for iPad doesn't always work properly with Tea Commerce?

     

  • Rune Grønkjær 1371 posts 3102 karma points
    Feb 04, 2013 @ 10:54
    Rune Grønkjær
    0

    Hi Ulrich and Haytse,

    Bingo. I found the problem.

    Safari (But only some Safari's) totally ignores the fact that we tell it to NOT cache the ajax calls to the server. In other words it will just respond right away, and not send the call to the server. The fix is to send a date stamp along with the data, which will trick Safari to think that we are sending completely new data.

    I have made a fix on the starter kit web site where you guys can download the latest JavaScript files.
    http://starterkit.teacommerce.net/scripts/TeaCommerce/teaCommerce_unpacked.js
    http://starterkit.teacommerce.net/scripts/TeaCommerce/teaCommerce.js

    Try it out and see if that won't fix it for you as well.

    Note that the latest JavaScript only works for the later versions of Tea Commerce. It's only a few lines of code and can easily be added to an older version of the JavaScript, for at quick fix.

    /Rune

  • Haytse 3 posts 23 karma points
    Feb 05, 2013 @ 13:35
    Haytse
    0

    Hi Rune,

    Thank you for your speedy reply. I have tested it on my iPad 3 and everything seems to work correctly (as it did with the previous javascript after I cleared the cookies, history, website data, etc.). I'll still have to test it on the iPad Mini that had the same problem to be sure.

  • Rune Grønkjær 1371 posts 3102 karma points
    Feb 05, 2013 @ 15:08
    Rune Grønkjær
    0

    Cool. Nice to hear.

    /Rune

  • Anders Burla 2560 posts 8256 karma points
    Feb 11, 2013 @ 10:15
    Anders Burla
    0

    Hi Haytse

    Could you please mark the right answer as the solution to your problem? Thanks :)

    Kind regards
    Anders

  • Haytse 3 posts 23 karma points
    Feb 21, 2013 @ 09:25
    Haytse
    0

    Can I do that seeing as I'm not the OP?

    If I try to "High five!" Rune's post it says I need at least 70 karma points in order to be able to do that.

Please Sign in or register to post replies

Write your reply to:

Draft