jQuery version clashes - javascript

I have sort of run into an issue.. I am possibly using way too much jquery on my site now, and all the scripts require their own version of jquery at the moment.. so they're pretty much clashing and with them all included into one page, nothing works.
Is anyone able to give me some advice on how to get around this?
So far I am using:
https://ajax.googleapis.com/ajax/libs/jquery/1.5.1/jquery.min.js
http://code.jquery.com/jquery-latest.js
http://ajax.googleapis.com/ajax/libs/jqueryui/1.8.7/jquery-ui.js
http://pastebin.com/kWZHNiiu
I've tried removing just one or two, and they all fall into a loop of some working, and others not. The main issue seems to be really coming from the version 1.2.3 > http://pastebin.com/kWZHNiiu
Thank you
- James

Look into http://api.jquery.com/jQuery.noConflict
Although I would suggest to use only one version for your site.

Related

Chrome crashing on page load

I'm developing a site on Silex + Twig. Most of the time, everything looks great, but once in a while, without any JS errors, chrome will crash the page just after loading the content.
It only happens on some computers, what made me think that it might be a memory problem.
Unfortunately, I cannot provide any code, mostly because I would have to provide the whole source code, since I cannot pinpoint the problem.
Have any of you ever had problems like this? If so, how did you solve it? Where should I look first? Please, if you can, send me some light on this matter.
EDIT: On the beginning of the project, this started happening A LOT, like 3 out of 4 refreshes, so we switched from Symfony to Silex... In my machine, it solved the problem, but in some others, it still happens, in minor frequency.
I got it...
It was a problem with the flexslider plugin.
In this question there's the explanation and solution:
Bootstrap + Flexslider: Loading Flexslider within hidden element causes jQuery to be unresponsive
Thanks anyway... :D

Rhinoslider not working "Effect for explode not found"

Im trying to use the awesome jQuery Rhinoslider plugin, however it does not work one bit.
Not even the demo i downloaded works, it just throws Effect for explode not found and "Preparations for explode not found" in the console.
I choose the effect explode but this happens with every effect, even if i choose none as effect.
The documentation is pretty poor regarding this kind of questions and you dont find a lot of answers on the internet for this plugin..
Does anybody know what this logs mean? I included every other scripts (easing, mousewheel) and as said, not even the demo i downloaded is working.
Thanks very much!
You probably need explode effect from jqueryUI download page
I had the same "Effect not found" issue and I solved it with downloading again the slider from http://rhinoslider.com/demo-download/
You may need to check all the effects or the effects you need, because they are not checked by default.

Cloning a DIV with multiple inputs in Jquery Mobile

I'm new to javascript and I can't seem to figure out this thing which I reckon should be a no-brainer.
I'm using Jquery mobile. I would like to clone a div and update the IDs of the elements in it. This seems to work fine. However, I can't get the cloned select element to work properly. I doesn't seem to work - I can't select anything - after its been cloned. When I call an extra $('html').trigger('create'); on the page the select elements starts looking 'funny' (probably because it got enhanced a second time) but does works.
I've posted a simplified version of my code here: http://jsfiddle.net/cUBPF/1/
Does anyone have a suggestion for me?
Thanks!
I'm not experiencing any problems however I'm just using my desktop. My first thought is to avoid calling the $('html').trigger('create'); at all and simply do what you want to within the clone_button click but then again, I'm not really sure what you are doing.
Instead of doing all this, why not output 10 or 20 of these fields and the display:none/display:block them......I assume you will run into less compability issues this way and you really don't want to allow infinite amount of fields....your going to run into browser memory issues which is just going to cause more bugs.

Internet Explorer 7+8 jQuery Error with infiniteCarousel

Hai guise! I am having a spot of trouble with some jQuery I am using, this was previously working but I have made many developments since then and tried to track back to find out what the issue was, but I am unsuccessful - hence, my presence on here. Anyway, I am getting some JS errors in both IE7 and IE8 with the catch my frame jQuery infiniteCarousel plugin, I am literally pulling my hair out over this as when you remove any reference to this everything works beautifully.
Here is a link to the page.
If anyone can shed any light on the matter you would be a life saver!
The problem is that the jQuery infinite carousel plugin is poorly written and the minifaction process requires well formed JavaScript. If you take his code and run it through JSLint you'll see it needs dozens of fixes before it's likely to minimize properly. This is something the author of the plugin needs to rectify.
Although it isn't throwing any errors, it seems that the plugin is loosing track of the elements. A possible solution would be to hook into the start and complete events and stop all the button events until it has completed the animation.
Alternatively, use this plugin instead: http://sorgalla.com/jcarousel/

need help with IE 6

so i've been working on a website now for like a couple months and i test it on chrome mainly. but before i release anything big i always check it on firefox 3.something and IE7. Now i've received some complaints that that it doesn't look very good in IE6 and when i do check it... well ya it doesn't look like its supposed to. Is there any quick fix that i can add to my HTML to make it look the same in IE6 as it does every where else?
At the risk of downvotes: have you tried adding IE6 to your test matrix? If you have a significant number of users complaining that it looks bad on IE6, you clearly have a significant number of users using IE6 to use it, so it seems like it would be worth your while to just add it to the set of browsers you check before release. Just sayin'.
A really good start is http://code.google.com/p/ie7-js/ Just place it in conditional comment tags in the head of your document and it will make ie6 'standards-compliant'. After that make sure you have seperate css documents for each version of IE, and make sure all of your code is valid with w3's validator. Also declaring a doctype can fix many issues, but it MUST be on the very first line that the browser sees.
Edit: also, for png transparency, I've found that this http://www.twinhelix.com/test/ (IE PNGFIX 2.0 Alpha) works best.
There is no quick trick to getting everything to work. Pretty much have to examine each element that looks different.
That said, you might try looking at a CSS reset file.
Yahoo has one.
And if you search google I'm sure you can find others.
Read this: Internet Exporer box model bug. Also try using YUI reset or Eric Meyer's resetReloaded to set a baseline for all your styles.
And stop developing in Chrome! Try Firefox with Firebug.
How badly does your website 'break' in IE6? If it's minor, then I wouldn't worry about it.
How critical is it that it works in IE6? It's share of the market is slowly but surely declining (Looking at my own logs from a Government website also shows that IE6 is definitely going away). Can you display a message on your website letting users know if they use IE6 and advising that they upgrade?
There are many reasons to upgrade, and educating your users as to why they should upgrade might also be worthwhile?
Uhm... if there is a simple solution I really want to know it. :)
But you can anyway use this good Microsoft tool to cross-test your pages.
It can be usefull for compare the final render of a website.
CSS resets will probably do nothing if it looks fine in IE7. Things like double margins when floating and overflow:auto bugs are things that need to be manually added for each occurance. I'd suggest adding the following line to your head tag:
<!--[if lt IE 7]><style type="text/css">#import "/stylesheets/ie6.css";</style><![endif]-->
and then writing an ie6.css file to fix all the bugs (yes, one at a time)
Probably not what you wanted to hear, but it is why everyone hates IE6 so much
you can check version of client browser and include css fixing for that browser. but most simple solution is to show an alert or notification to client that his browser is outdated and provide links to download latest browser
here are some way to show that notification
http://garmahis.com/tools/ie6-update-warning/
i like this solution
http://www.browser-update.org/

Categories

Resources