jQuery buttonset() impacted by Latest Chrome Update - javascript

A recent update by Google for their Chrome browser (31.0.1650.57 m) has caused an issue with jQuery's buttonset() where buttons are now showing vertically rather than horizontally as they should.
I found a work-around which is to set the 'display' css attribute to 'inline-block' after the initial buttonset() call. Attempts to set this attribute prior to this call are ignored (though they worked fine for prior versions of Chrome and work well in FireFox).
My question is whether others have experienced this and if so, can they shed light on why this is happening and whether there is a better way of addressing this than with my work-around?

Related

How best to fix Chrome datalist rendering

You may be aware that Chrome has problems with datalist/option autocompletes.
Essentially whilst it works in IE, Chrome doesn't allow you to scroll through the list and the list runs out of the browser into the main window.
My question is whether someone can suggest a good method of overriding the Chrome implementation, and what to override it with. Solution has to work in main modern browsers and mobiles
I had the exact same problem. I searched for 2 days and ended up using https://jqueryui.com/autocomplete/
It is far better than datalist.

IE8 not loading jQuery 2.0 even though it's the first include and it's loaded from the same domain?

I have a page in which I use jQuery for damn nearly everything, thus I find it kind of problematic when jQuery won't load in IE8 (works fine in IE9 and, I presume, IE10).
I've tried all the usual trickery: putting jQuery at the top of the header and I am loading the file from the same site as I am trying to run. I always do these things, but now you know ;)
The IE8 console isn't to much help, as it just bangs on about stuff being undefined, and not having this and that property and method. All i can get out of it is that the jQuery file is being loaded (it finds errors in that too :/), but for same reason it isn't working.
If someone would be so kind as to have a look at it, this is a link to the actual page.
jQuery 2.0 completely dropped support for IE 8. You need to use 1.10.2 to support IE 6,7,8
They both currently have all the same features and functionality but 2.0 and up is smaller in KB due to dropping legacy code for IE and earlier.
60% of my visitors are on IE8 so I will be using v1.x for a long time
It's not surprising that this doesn't work, because jQuery v2 does not support IE8.
It says so very clearly on the jQuery site.
You need to use jQuery v1.x if you want to support IE8 or earlier.
(the functionality of v1.10 is identical to v2; the only difference is that v2 removes all the extra code they had in there to support old IE versions)

error in Chrome when displaying inline-block li elements

I'm pretty new to web-coding and in my attempt to create jQuery based menu bars complete with dropdowns I have stumbled upon some vast differences between broswers. Below you can see that while FF and Safari are the same, IE is actually behaving and Opera is ok-ish, Chrome gets it totally wrong. As far as I can tell I have all the latest versions.
I removed the code from here and pasted it in: (doesn't want to let me link properly) so: jsfiddle.net/2hCR2/
Just in case, support for older versions of IE (6-7) is not required.
Right now I'm mostly concerned with the positioning aspect. Any assistance is much appreciated!
****EDIT:** After continuing to play with the chrome developer tools I realized that when I manually set the 1st list (pants/t-shirt) to display:block it displays as expected (exactly like FF and Safari in the image) so it appears that this is more of a javascript/jQuery issue not updating the DOM correctly(?). I also noticed that when I put the code is JSFiddle and ran the script in Chrome it produced the same error, but when I ran JSFiddle in FF (exact same fiddle link) it renders correctly.
It does not happen in Chrome Canary (version 24) but it does in stable (version 22). Apparently it is a bug which has been fixed.
You can either wait a month or two so that all Chrome users get the fix, or just use .show() instead of .show(0).

Internet Explorer 9 appearance conflict

I have been researching all over the internet about this, and unfortunately cannot find out why this is happening. It seems to only be happening in internet explorer 9, on certain computers.
The entire page looks like a mess only in IE 9 (some computers):
The URL of the website is Here
Can anyone tell me why this is happening in IE9?
(NOTE: Compatibility view cleans it, but then the Js/jQuery doesn't work right).
For some reason, IE thought that the site was in my intranet, and rendered it in Compatibility Mode (there's a setting in IE to automatically render intranet sites in CM).
When I unchecked the box to "automatically detect intranet network", the site rendered correctly.
So your real question is how does IE determine the intranet network, and how can you force your page to NOT render in Compatibility Mode... something like this.
I noticed that you have blank space above your doctype. IE hates this. The doctype needs to be the very first thing in the file.
You also have over 2300 HTML validation errors that should be investigated and rectified. Again, IE is very sensitive to invalid HTML.
Going on a whim here, but I think it's the usage of inline-block. I don't have IE9 installed to a point where I can use it's developer console to further inspect, but IE is known to be very bad about displaying inline-block elements.
In Google Chrome's console, I am able to replicate the same appearance using float:left as opposed to display:inline-block, so that should solve that piece of the issue.
Edit: The only syntax issue I see with the HTML is the placement of the </head> tag, which is not adjacent to the <body> tag.
Edit 2: As far as the outlining issue goes, try using this answer to another question.
Edited yet again to fix the display of the tags.

Javascript in IE8 very slow, IE7 + others fast using jQuery, jQuery UI, nyroModal

The page is rendered within an nyroModal (loaded via ajax) and the DOM is manipulated quite a bit using several plugins before actually showing the page.
Everything is fine in non-IE-Browsers and IE7, but in IE8 the resizable and draggable of an div is very slow and crawles along.
I know IE8 is slow. I know my DOM is big. I know i use a lot of plugins. My question is, what exactly slows it down, as other Browsers do it well?
I deactivated every plugin after each other to locate the culprit. Only having resizable activated it is still slow.
I used IE8 profiler and it says offset uses most of the time.
EDIT: I analyzed the page using dynaTrace AJAX Edition and it showes me that these 2 functions are responsible for the most exec time:
jQuery.fn.offset = function(options)
and
jQuery.expr.filters.hidden = function(elem)
both in jquery.js
i read somewhere that IE8 has problems with offset, but how can i circumvent this?
Edit2: I builded a test-page with just a link to open the page with all the resizing in a modal. works nice also in ie8 ! so i guess the big DOM of the modal-parent-page is the problem.
any advice appreciated!
Dynatrace has a very good javascript profiler. Check it out.
Check that your browser is not running in IE7 emulation mode.

Categories