You need to be logged in to post in the forums. If you do not have an account, please sign up first.
Error with Jquery
I am experiencing problems using Dragonfly since, so I trigger, starts to appear in Jquery error as reported below, this is happening to someone else?Unhandled DOMException: SYNTAX_ERR
Thanks for the help
try {
matches.call( div, "[test!='']:sizzle" ); <---------- This line
rbuggyMatches.push( Expr.match.PSEUDO );
} catch ( e ) {}
About Opera
Version information
Version
12.01
Build
1532
Platform
Win32
System
Windows 7
XHTML+Voice
Plug-in not loaded
Browser identification
Opera/9.80 (Windows NT 6.1; U; en) Presto/2.10.289 Version/12.01
By the way, there are two line of comment above the try/catch block here reported, that say "// This should fail with an exception // Gecko does not error, returns false instead", so only gecko-based browsers don't throw the exception
Do you think this is an error I should report to the jQuery team or was this an intentional design feature that should be throwing the error (for some reason?). Basically, do you know why this is happening? I'm an amateur javascript developer and just like to understand more about why these things are happening. Was there a reason only gecko browsers shouldn't throw the exception or should I direct these questions to the jquery team?
Originally posted by daidoji70:
Do you think this is an error I should report to the jQuery team or was this an intentional design feature that should be throwing the error (for some reason?).
I don't know... there is the ticket in the jQuery bug tracker (see http://bugs.jquery.com/ticket/12422), but it is closed.
Mac Opera, on the other hand, completely fails all JQuery (Opera 12.0). Totally. (http://jqueryui.com/themeroller/#themeGallery for example, comes up as unstyled content, all the JQuery functionality has Poofed. Poof!)
Methinks Opera, who is a big promoter of HTML5, has performed some political villainy here... truth?
BTW the version of JQuery used is 1.8.1. In Mac Opera even 1.7.2 is buggy. But only in Opera. What gives here?
If dragonfly is open, sometimes it reports an error on the only line of jquery.min.js Unhandled DOMException: SYNTAX_ERR.
I press Continue (F8), no problem.
The below code fails on "document.querySelectorAll('div.operaBroken');", there is an "Uncaught Exception: TypeError cannot convert to Object" when defining a selected DOM object.
I've reinstalled Opera 12.02 from scratch. This being an unhandled exception, perhaps this is clearly a bug in browser JS handling?
<!DOCTYPE HTML>
<html>
<head>
<meta charset="UTF-8">
<title>Untitled Document</title>
<script type="text/javascript">
window.onload = docLoad();
var changeUp1 = document.querySelectorAll('div.operaBroken');
var changeUp2 = document.querySelectorAll('div.footergap');
function docLoad() {
if ((navigator.userAgent.indexOf("Opera") > -1) && (navigator.userAgent.indexOf("Mac") > -1)) {
changeUp1.style.display='block';
changeUp2.style.display='none';
}
}
</script>
</head>
<body>
<p class="operaBroken" style="display:none;"> broken!</p>
<p class="footergap" style="display:block">footergap</p>
</body>
</html>
Originally posted by fredvlad:
window.onload = docLoad();
this is wrong. you're not assigning the function to onload, what you're actually doing is immediately executing docLoad and passing the result to window.onload. i.e. you're executing the function before the document has finished loading, so it's not surprising your code throws.
try
window.onload = docLoad;
instead;
Originally posted by fredvlad:
Mac Opera, on the other hand, completely fails all JQuery (Opera 12.0). Totally. (http://jqueryui.com/themeroller/#themeGallery for example, comes up as unstyled content, all the JQuery functionality has Poofed. Poof!)
all works fine for me on Mac.
Originally posted by fredvlad:
Methinks Opera, who is a big promoter of HTML5, has performed some political villainy here... truth?
aeh...what?
Originally posted by patrickhlauke:
If you turn that toggle off, everything works fine. We're discussing changing/uncoupling those two settings in future revisions of Opera Dragonfly.
It'd be great if you can do something to make Dragonfly work a bit nicer with jQuery, I was originally thinking some sort of optional "ignore exceptions when thrown by script X" list. I always end up just turning off break on exception if JQ is involved!

However, out of the box Opera 12.02 for Mac OS X 10.6.8 build 1578 does not display JQuery, still. Even after the Scripts "Show Parse Errors" is unchecked. http://jquerymobile.com/demos/1.2.0/docs/pages/loader.html or http://jqueryui.com/accordion/
Ugly, ugly. No styling whatsoever. Fails to provide functionality and styling.
And the reason for this is...? Does anyone else see this? Prove me wrong. Please.
BTW removing argument parens for docLoad was correct, my bad. Still, JQuery does not work. I must presume to turn away users with Mac on Opera when using JQuery.
Originally posted by fredvlad:
However, out of the box Opera 12.02 for Mac OS X 10.6.8 build 1578 does not display JQuery, still. Even after the Scripts "Show Parse Errors" is unchecked. http://jquerymobile.com/demos/1.2.0/docs/pages/loader.html or http://jqueryui.com/accordion/
Ugly, ugly. No styling whatsoever. Fails to provide functionality and styling.
And the reason for this is...? Does anyone else see this? Prove me wrong. Please.

Originally posted by fredvlad:
BTW removing argument parens for docLoad was correct, my bad. Still, JQuery does not work. I must presume to turn away users with Mac on Opera when using JQuery.
you must be doing something wrong somewhere along the line (your settings perhaps?), because it works...
Originally posted by patrickhlauke:
you must be doing something wrong somewhere along the line (your settings perhaps?), because it works...
for instance, you sure you haven't accidentally set the site preferences for jquery.com or similar to not have JS enabled?
http://desertbiz.biz/screenshot.jpg
This applies to ALL JQuery pages. Destroys the UI completely. Ain't my settings...
A,UCD puppies?
S, ICD puppies.
Well, MNO puppies...
Hmm, S, AR puppies! CMPN?