Author Topic: Product reloading seems to doesn't work on IE9  (Read 4903 times)

Studio 42

  • Contributing Developer
  • Sr. Member
  • *
  • Posts: 3907
  • Joomla & Virtuemart developper
    • Studio 42 - Virtuemart & Joomla extentions
  • VirtueMart Version: 2.6 & 3
Re: Product reloading seems to doesn't work on IE9
« Reply #15 on: March 24, 2015, 23:22:05 pm »
Hi miku,
You have many solution for this problem.
one is (remove ajax and go to page)  after :
Quote
    Virtuemart.updateContent = function(url) {
add
Quote
    if (document.all && !window.atob) window.location.href = url;
to detect IE9 and lower
See here for more possibility :
http://stackoverflow.com/questions/10964966/detect-ie-version-prior-to-v9-in-javascript

Miku

  • Jr. Member
  • **
  • Posts: 79
  • A beginner
  • VirtueMart Version: 3.0.18, J!3.6.4
Re: Product reloading seems to doesn't work on IE9
« Reply #16 on: March 25, 2015, 09:47:43 am »
Thanks for a hint but it looks like I'm not able to make use of it - it doesn't work for me. Should the code look like below after the modification? It's not that I'm too lazy to make some effort to do something by myself, it's simply because I'm not a programmer at all  :-[
Code: [Select]
Virtuemart.updateContent = function(url) {
if (document.all && !window.atob) window.location.href = url;
        if(Virtuemart.isUpdatingContent) return false;
        Virtuemart.isUpdatingContent = true;
        url += url.indexOf('&') == -1 ? '?tmpl=component' : '&tmpl=component';
        console.log("UpdateContent URI "+url);
        $.ajax({
            url: url,
            dataType: 'html',
            success: function(data) {
                var el = $(data).find(Virtuemart.containerSelector);
if (! el.length) el = $(data).filter(Virtuemart.containerSelector);
if (el.length) {
Virtuemart.container.html(el.html());
                    Virtuemart.updateCartListener();
                    Virtuemart.updateDynamicUpdateListeners();
                    //Virtuemart.updateCartListener();

if (Virtuemart.updateImageEventListeners) Virtuemart.updateImageEventListeners();
if (Virtuemart.updateChosenDropdownLayout) Virtuemart.updateChosenDropdownLayout();
}
Virtuemart.isUpdatingContent = false;
            }
        });
        Virtuemart.isUpdatingContent = false;
    }
By the way indeed the best solution for me would be complete getting rid of the 'ajax reloading for product details', but how to do this?

Milbo

  • Virtuemart Projectleader
  • Administrator
  • Super Hero
  • *
  • Posts: 9853
  • VM3.2 Cached and Optimized
    • VM3 Extensions
  • VirtueMart Version: VirtueMart 3 on joomla 3
Re: Product reloading seems to doesn't work on IE9
« Reply #17 on: March 25, 2015, 11:00:03 am »
Miku, I think Patrick meant it that way. Our problem is that there are not a lot people with an IE9. My personal statistic is that there are 2% developers with a real IE9, the rest tries with emulations, which have their own problems.
I should fix your bug, please support the VirtueMart project and become a member
______________________________________
Extensions approved by the core team: http://extensions.virtuemart.net/

Studio 42

  • Contributing Developer
  • Sr. Member
  • *
  • Posts: 3907
  • Joomla & Virtuemart developper
    • Studio 42 - Virtuemart & Joomla extentions
  • VirtueMart Version: 2.6 & 3
Re: Product reloading seems to doesn't work on IE9
« Reply #18 on: March 26, 2015, 02:25:06 am »
I have look for statistic. IE8+9. Usage is +/- 7%, depending the stat counters you look.
Milbo, I think, it would be nice that your developpers do something.

Miku

  • Jr. Member
  • **
  • Posts: 79
  • A beginner
  • VirtueMart Version: 3.0.18, J!3.6.4
Re: Product reloading seems to doesn't work on IE9
« Reply #19 on: March 26, 2015, 08:40:18 am »
Milbo, I think, it would be nice that your developpers do something.
I agree, if not just for IE then maybe some option to completely disable the ajax reloading...

Milbo

  • Virtuemart Projectleader
  • Administrator
  • Super Hero
  • *
  • Posts: 9853
  • VM3.2 Cached and Optimized
    • VM3 Extensions
  • VirtueMart Version: VirtueMart 3 on joomla 3
Re: Product reloading seems to doesn't work on IE9
« Reply #20 on: March 26, 2015, 08:50:44 am »
I have look for statistic. IE8+9. Usage is +/- 7%, depending the stat counters you look.
Milbo, I think, it would be nice that your developpers do something.
I did already something and tested your ideas, but without luck. So my solution is a try/catch now.

Code: [Select]
        try {
            history.pushState(stateObj, "", url);
        }
        catch(err) {
            // Fallback for IE
            window.location.href = url;
            return false;
        }

and a config to disable the dynupdate (hmm should be called reload, actually) is already there. jdynupdate, and here the tutorial how to set http://forum.virtuemart.net/index.php?topic=128956.0

But others asked also for an option, not any developer for customplugins or joomla content plugins knows how to add the right js.
I should fix your bug, please support the VirtueMart project and become a member
______________________________________
Extensions approved by the core team: http://extensions.virtuemart.net/

Milbo

  • Virtuemart Projectleader
  • Administrator
  • Super Hero
  • *
  • Posts: 9853
  • VM3.2 Cached and Optimized
    • VM3 Extensions
  • VirtueMart Version: VirtueMart 3 on joomla 3
Re: Product reloading seems to doesn't work on IE9
« Reply #21 on: March 26, 2015, 09:07:57 am »
I have look for statistic. IE8+9. Usage is +/- 7%, depending the stat counters you look.
Milbo, I think, it would be nice that your developpers do something.

You did not read correctly, I did not say that there are only 2% using it. What I said is, that I asked 50 people and only ONE has a real IE9. So the statistic within this forum is 2% and the reason that it is so hard to check for it, because there is no developer using such an old browser.
I should fix your bug, please support the VirtueMart project and become a member
______________________________________
Extensions approved by the core team: http://extensions.virtuemart.net/

Studio 42

  • Contributing Developer
  • Sr. Member
  • *
  • Posts: 3907
  • Joomla & Virtuemart developper
    • Studio 42 - Virtuemart & Joomla extentions
  • VirtueMart Version: 2.6 & 3
Re: Product reloading seems to doesn't work on IE9
« Reply #22 on: March 26, 2015, 12:20:07 pm »
Look here :
5% > http://www.h3xed.com/web-development/should-your-new-website-support-internet-explorer-8-in-2015
25% > http://www.w3counter.com/globalstats.php
25% > https://www.netmarketshare.com/browser-market-share.aspx?qprid=2&qpcustomd=0

The problem is the Microsoft ie8 update policy for windows 98,XP and Xbox.
I know 25% is not real, but i think the 7% is real !

Milbo

  • Virtuemart Projectleader
  • Administrator
  • Super Hero
  • *
  • Posts: 9853
  • VM3.2 Cached and Optimized
    • VM3 Extensions
  • VirtueMart Version: VirtueMart 3 on joomla 3
Re: Product reloading seems to doesn't work on IE9
« Reply #23 on: March 26, 2015, 12:27:40 pm »
Paatrick, wake up. I am NOT talking about the percentages in the wild.

I talk about developers! in special VirtueMart developers!
I should fix your bug, please support the VirtueMart project and become a member
______________________________________
Extensions approved by the core team: http://extensions.virtuemart.net/

Miku

  • Jr. Member
  • **
  • Posts: 79
  • A beginner
  • VirtueMart Version: 3.0.18, J!3.6.4
Re: Product reloading seems to doesn't work on IE9
« Reply #24 on: March 26, 2015, 14:49:52 pm »
I did already something and tested your ideas, but without luck. So my solution is a try/catch now.
Code: [Select]
        try {
            history.pushState(stateObj, "", url);
        }
        catch(err) {
            // Fallback for IE
            window.location.href = url;
            return false;
        }
Indeed, it seems to work ;)
and a config to disable the dynupdate (hmm should be called reload, actually) is already there. jdynupdate, and here the tutorial how to set http://forum.virtuemart.net/index.php?topic=128956.0
Yes, jdynupdate helps but it causes another problem - facybox doesn't work :(

Milbo

  • Virtuemart Projectleader
  • Administrator
  • Super Hero
  • *
  • Posts: 9853
  • VM3.2 Cached and Optimized
    • VM3 Extensions
  • VirtueMart Version: VirtueMart 3 on joomla 3
Re: Product reloading seems to doesn't work on IE9
« Reply #25 on: March 26, 2015, 15:25:27 pm »
what about the facebox?
I should fix your bug, please support the VirtueMart project and become a member
______________________________________
Extensions approved by the core team: http://extensions.virtuemart.net/

Miku

  • Jr. Member
  • **
  • Posts: 79
  • A beginner
  • VirtueMart Version: 3.0.18, J!3.6.4
Re: Product reloading seems to doesn't work on IE9
« Reply #26 on: March 26, 2015, 15:34:19 pm »
what about the facebox?
When we use jdynupdate in config there's an issue with 'Recommend to a friend', 'Print' and 'Ask a question' forms
They are loaded in the new page instead of the pop-up window, respectively:
/recommend?tmpl=component
?tmpl=component&print=1
/askquestion?tmpl=component

Miku

  • Jr. Member
  • **
  • Posts: 79
  • A beginner
  • VirtueMart Version: 3.0.18, J!3.6.4
Re: Product reloading seems to doesn't work on IE9
« Reply #27 on: March 26, 2015, 15:48:11 pm »
what about the facebox?
And of course, above all, there is an issue with images which load itself  in a new page instead of pop-up...So we have something like /images/stories/virtuemart/product/image.jpg in the url.

Miku

  • Jr. Member
  • **
  • Posts: 79
  • A beginner
  • VirtueMart Version: 3.0.18, J!3.6.4
Re: Product reloading seems to doesn't work on IE9
« Reply #28 on: March 26, 2015, 17:17:07 pm »
Now when the reload works thanks to your 'try/catch' solution I see another issue - issue with sub-menu items (rolling out items). The menu levels are distorted after we choose some of the variant of a product. By distorted I mean the sub-menu is in the same line as the main one (it's not rolling out outside)  When I took a look at the case thoroughly it looks like issue appears only for central variants of a product - when we choose the first one or the last one of the variants everything works fine... Very strange but it works that way...

AH

  • Global Moderator
  • Sr. Member
  • *
  • Posts: 2915
  • VirtueMart Version: 3.6.0
Re: Product reloading seems to doesn't work on IE9
« Reply #29 on: March 26, 2015, 19:30:29 pm »
MOVE ON please !

Yes there are stats out there on users with IE8

Stick a banner up like the very well visited BBC.co.uk does if a visitor uses an outdated browser -

If they are still using XP or IE8 then it is time they progressed into the 21st century, they can always stick firefox on their machine and have an updated browser.

Why on Earth should the team waste time looking back at a browser that should be dead?



regards
A

Joomla 3.9.8
php 7.1