errors in sortables demos
On the sortables documentation page, after dragging an item, there is an error "self.pos has no properties". About a second later a sequence of errors occur that number in the thousands after a few seconds. The error is "this.parentNode has no properties". I've seen this happen in Firefox 2 on Ubuntu and Windows. All the sortables demos on the UI site also have the same errors.
IE bug with radio buttons 'checked' status and toggle animation
Hey guys, Haven't been able to find a solution to this anywhere on the web. Have a div toggle('slow') jquery function. In that div there are radio buttons which are being 'checked' by PHP. Everything works okay until I hide and then show the div - all my radio buttons lose their 'checked' status. On IE7 and VISTA. Seems if I do toggle() without the animation, everything is fine though. Any response would be greatly appreciated!
Debugging Accordion on Safari 2
Hi folks, I need some help debugging the accordion on Safari 2. Neither the old standalone plugin nor the UI version work as intended. I'm lacking the necessary development enviroment to debug anything. A demo for the UI accordion is here: http://dev.jquery.com/view/trunk/plugins/ui/demos/ui.accordion.html The source for the plugin here: http://dev.jquery.com/view/trunk/plugins/ui/ui.accordion.js What I could observer (via browsercam): The old version initialiazes correctly (hides parts of the accordion),
document.write() in injected HTML
I want to be able to call load() on any HTML, but there is a problem with HTML that includes JavaScript that uses document.write() . I think it would be nice if injected HTML would handle document.write() correctly, so I changed jQuery 1.2.1 to handle this. I hope something like this can be included in jQuery in the future. (I'm a Java programmer who isn't very familiar with JavaScript, so I hope the code isn't too bad.) Here is my fix: --------------------------- domManip: function(args, table,
unique(array) function - bug ticket 1747
Thought I'd post here in case it was missed on the main list. This is from the example at <a href="http://docs.jquery.com/Utilities/jQuery.unique">http://docs.jquery.com/Utilities/jQuery.unique</a> $.unique([0,1,1,2,2,3]) expected: [0,1,2,3] actual: [0,1,1,2,2,3] Created ticket, attached patch with unit tests and possible fix: <a href="http://dev.jquery.com/ticket/1747">http://dev.jquery.com/ticket/1747</a> - Richard
Form plugin: dealing with Safari upload 'stalling'
Hello, Safari has a bug which occasionally makes it 'stall' / 'halt' during the post of a form that contains a file upload. I don't know under which specific conditions this problem occurs, but the problem has been reported by others as well. There is also a hack available to solve this issue: - http://www.webmasterworld.com/macintosh_webmaster/3300569.htm - http://blog.airbladesoftware.com/2007/8/17/note-to-self-prevent-uploads-hanging-in-safari I did a minor tweak to .ajaxSubmit and I suggest integrating
Unicode range for allowed chars in quickChild, quickID, quickClass
Hi there, I am curious about the following regexp definition for the allowed chars: "(?:[\\w\u0128-\uFFFF*_-]|\\\\.)" Why does the range start at "\u0128"? Is it meant to be "\u0080" instead? Tim.
modifications for offset()
Probably @Brandon primarily... I have a test version of some changes for offset(), basically: - updated safari2 body offsets handling - updated mozilla table handling and borders handling - added thin/medium/thick border handling - slightly modified IE body borders handling For part of the testing I took the liberty of using and adding to your visual test page(s) - an extra absolute and a table - as a consequence of which I have played around with the links a bit! (There is also an additional DIV#page
test for iphone with jquery ...
is this possible ?
Problem with IE 6.0
IE7 and Fifo 2 looks fine. In IE 6 some Edges are not rounded. It really looks terrible... Does anyone got an idea? in my php document: <!--[if IE]><script type="text/javascript" src="skript/ excanvas.pack.js"></script><![endif]--> <script type="text/javascript" src="http://code.jquery.com/jquery- latest.pack.js"></script> <script type="text/javascript" src="skript/jquery.corner.js"></script> <script type="text/javascript"> $(document).ready(function() { $("#nav a").corner("6px top #36f");
AJAX post request, from and to the same webpage - does not work in IE6
Hello, After a lot of research I found out that doing an AJAX post request, in which the page that the request originates from and the page that is requested are the same, does fail in IE6. So f.e. page test.php contains javascript which sends an AJAX post request (in my case as the result of a form submit) to test.php. test.php now returns a different version of itself (without the AJAX request). This is, as far as I know, pretty common practice. It works for all browsers I tested (FF2, IE7, Opera9,
question about change in behavior
In jQuery 1.0.4 you could do something like this: $("#something").filter("[@name]", function(){ /* do something */ }); In jQuery 1.1+ this is not possible anymore, I'd need to do something like: $("#something").filter("[@name]").each( function(){ /* do something */ })); I'm just wondering if this is documented somewhere, I went through the 1.1 release notes but I couldn't find anything about it. I'm wondering if there are other functions that would have had the same change in behavior. Thanks, Carlos
jQuery evaluates a script tag before the HTML is appended to the DOM?
Can someone take a look at the following? http://dev.jquery.com/ticket/1725 I don't understand lines 402 and 403 of jquery-1.0.2.js: 402: if ( !evalScript(0, elem) ) 403: fn.call( obj, elem ); where "fn" can be either "appendChild" or "insertBefore". If it's going to insert HTML into the DOM, why does it have to try to evaluate first and then append it into the DOM. The problem is that "elem" can contain script tags that work under the assumption that HTML that is also contained in elem will be added
iPhone feedback on ticket
Could anyone with an iPhone provide some feedback about ticket #1563? The claim in ticket #1563 is that $('p:eq(1)').hide() does not work. If someone could run a few tests to see if this is true and if it is the hide method itself or just the selector, that would be awesome. :) BTW ... I've tested this in Safari 3 beta and it works just fine. <a href="http://dev.jquery.com/ticket/1563">http://dev.jquery.com/ticket/1563</a> -- Brandon Aaron
wrap removes expandos (jQuery 1.2.1)
When you create an element (using document.createElement) and add expands to it, they are removed when that element is used to wrap another one. Example: http://www.texotela.co.uk/wrapexpandos.php I use this method for my focusfields plugin, and as a result it does not work in Internet Explorer if jQuery 1.2.1 is used.
IEContentLoaded article
<HTML><BODY style="word-wrap: break-word; -khtml-nbsp-mode: space; -khtml-line-break: after-white-space; ">Hey everyone,<DIV><BR class="khtml-block-placeholder"></DIV><DIV>I suspect that many of you have seen this already, but I thought I'd post a link in case it can be of use for getting $(document).ready to work well in IE:</DIV><DIV><BR class="khtml-block-placeholder"></DIV><DIV><A href="http://www.hedgerwow.com/360/dhtml/ie-dom-ondocumentready.html">http://www.hedgerwow.com/360/dhtml/ie-dom-ondocumentready.html</A></DIV><DIV><BR
IE Bug?
Got a little something I noticed in 1.1.3 that seems to still be hanging around. Sometimes I use 'find' to verify that a dom object is indeed a child of a parent like so: $('#parent').find(child); When child is an actual dom object I get a error in IE. I realize using a dom object as a selector isn't really standard jQuery usage and isn't mentioned in the docs, but I like it, so I tracked it down this afternoon and thought I'd post a fix. jQuery 1.2.1 line 227 inside the find method. return this.pushStack(
Google AdSense via remote loading (with Karl Tabs) error
$('#foo').tabs({ remote: true }); The remote file have AdSense code. When the tab is been clicked or triggered, getting "uncaught exception: Permission denied to call method XMLHttpRequest.open Line 0" error The line is not trackable with Firebug though. Anyone has any clue or suggestions? TIA jQuery 1.1.2 Tabs 2.7.3 -- <?php echo 'Just another PHP saint'; ?> Email: rrjanbiah-at-Y!com Blog: http://rajeshanbiah.blogspot.com/
memory leaks
Hi Running the following very simple test in 'drip' (http:// www.outofhanwell.com/ieleak/index.php?title=Main_Page), you can see memory being used but not freed. I noticed the memory growing on a larger app I was working on, and decided to investigate further. The memory leak only seems to occur when the event is bound. If the mousedown() line is commented out, no memory leak occurs. I have run the same test on v1.1.4, v1.2, v1.2.1 <div id='fred'>testtesttesttesttest</div> <script type="text/javascript">
spaces in code.
We can find ' ' (four spaces) in /src/*.js files. totally 12. 1 in ajax.js 3 in core.js 1 in event.js 7 in offset.js They should be 'Tab'.
Konqueror and 1.2.1
Seems like poor old konqy needs some love, again... - version: (userAgent.match(/.+(?:rv|it|ra|ie)[\/: ]([\d.]+)/) || []) [1], + version: (userAgent.match(/.+(?:rv|it|ra|ie|or)[\/: ]([\d.]+)/) || [])[1], --markc
wrap() executing javascripts again
This code worked fine when i used 1.1.2: $('table.main').wrap('<div class="galaxybg"></div>'); (table.main contains <script> tags in some of the cells). After updating to the recent 1.2.1, this code causes the scripts in <script> tags to be executed again. I fixed that for me with $('table.main script').remove(); but imho this behaviour is a bug.
filtering, cleaning AJAX loads
What would be the best way to inherently filter or sanitize all HTML loads? What concerns me the most are images. -- HLS
IE7 Image Load
Hi I am building dynamic Chess boards in jQuery over at 64squar.es. The HTML is rendered after the $(document).ready() event. Works great in FF, however in IE7 - sometimes the piece images (and in fact the rest of the images) only partially load (as in some of the pieces load, but not the others). I can't find any documentation on the internet about this 'feature'. Does anyone have any ideas why this might happen or how to prevent it? It occurs for background images and img tags - prerendering them
eval() logic in jQuery
Can someone explain the logic, maybe even the history of how and when eval() is used in jQuery? I am trying to grasp the security nature of using jQuery. I've been too loose with using jQuery in our product and now I need to clean it up before we release our new update that includes some enhancd "Web 2.0" areas with jQuery features. For example, in one usage, I had to use evalScript() to process any embedded scripts. On one usage, I didn't want it because the data was externally defined and yet to
Adding the possibility to match other namespaces attributes
I have noticed that you cannot match other namespaces attributes in the selectors... When you use XHTML and you want the document to still be valid, you can add other namespaces: <html xmlns="http://www.w3.org/1999/xhtml" bf:xmlns="blankFields" swap:xmlns="swapImages"> ... And use it: <form><input bf:value="Buscar..." type="text" accesskey="b" name="buscar" id="buscar" /></form> .... But when you try to find it with jQuery, it crashes: $("input[bf:value]").focus(focusField) --- I think
Bug in jQuery.fn.toggle?
See... I bound two functions using $().toggle, then when I use trigger('click',[foo]) on the element, it doesn't pass the extra arguments. If I'm not mistaken, the error is in line 1900 of jQuery 1.2.1 uncompressed.. Instead of: return a[this.lastToggle].apply( this, [e] ) || false; It should be return a[this.lastToggle].apply( this, arguments ) || false; I tracked the extra arguments and they got safely till there. I hope that helps.
strange problem with closures
Edge rails has a feature :cache - where it will concatenate all your javascript files into one all.js However when I did this I found that it mattered where I put various plugins. - and errors would be thrown. Needless to say I put jquery.js first. E.g. I wrapped rating,js in a closure thus : (function($){ $.fn.rating = function(url, options) { etc.. })(jQuery); If it occured just after image_search.js, which ended : ImageSearch.buttonAction = function(query) { loadScript("http://search.yahooapis.com/ImageSearchService/V1/
background style from external css bug?
in main html i include .css so: <link type="text/css" rel="stylesheet" href="my.css" /> then declare in my.css #my { background-position: 50% 50% } when i try to get style "background-position" with $ ("#my").css('backgroundPosition') or $("#my").css('background- position') i recieve just "undefined", but when i use <div style="background-position: 50% 50%"></div> it works fine. what the point? ps. jquery 1.2/FF2.0.6 pps. $("#my").css('background') doesn't work too, but $ ("#my").css('background-image')
IE bug in animate
starts at line 2583 end = parseFloat(parts[2]), IE throws an error here - perhaps because 'end' is a reserved word ? Anyhow converting to _end (and ~8 subsequent references) fixes the problem. Also added a ticket to Trac
Returning an array of elements hidden state
I would like to return an array of selected elements hidden state. I ended up using an each method and building the array: var states = []; $items.each( function() { states.push($(this).is(":hidden")); }); and this works fine, but after spending a good bit of time exploring and finally use the above, I was curious if there is a more direct jQuery idiom to obtain the list or array of the current "display' state of elements? Basically, I have a set selected items that are are either showing or not,
potential bug in .val() element for non-form elements, new in 1.2
This is a cross-post from the general list, where I first mentioned the issue. I have discovered a potential bug, or at least difference between 1.1 and 1.2, when using the .val() method. Previously, when running this on a non-form element (usually a link), it would return null or perhaps undefined (a 'falsy' value). Now it generates an error which halts script execution. Below is a stripped-down example of how I am using it in my code. The line which breaks is: item: $.trim($(event.target).attr("src")
Bug in offset() for IE
This probably Brandon's area ... The inclusion of an HTML element with an id of 'box' causes IE to fail in the offset method, reporting that "Object doesn't support this property or method" and relating to elem.getBoundingClientRect(). This is even though it has just passed a logic test for it! The solution is to declare box locally, ie change box = elem.getBoundingClientRect(); to var box = elem.getBoundingClientRect(); The problem and solution can be seen demonstrated at http://www.wizzud.com/tester/offset_quirks.html
Two quick bugs
Both bugs found on firefox, i have not checked other browsers sorry 1. Demo application Steps to reproduce: - Select landscape - Resize images so that scrollbar on the right appears - scroll down to the bottom - hover over an image - animation appears over an actual image, looks like a problem with scroll offset 2. Sortables demo / Nested lists - drag "and change" item tree under "positions" item tree - now drag "positions" tree - the "and change" tree appears twice once as a ghost and second instance
Understanding cancel process
In jquery.jeditable.js around line 230 (depending on the version your looking at - I am using SVN), is the following code: if ('cancel' == settings.onblur) { jQuery(i).blur(function(e) { t = setTimeout(reset, 500); }); Why is there a setTimeout function? What effect will calling the reset() function directly have? I am currently looking at the datePicker custom field usage under jEditable and when clicking outside the calendar I get the delay before the underlying input tag is closed. Thanks mrAnt
discussion about some improvements in semantic of some functions
Hi, As John requested I repeat the suggestions for the future of some functions here hoping for coments. text() ------ Should return an array with all texts of the nodes in the jQuery object. The current behaviour can be easily simulated by $('.asdf').text().join(''). Drawback: Current code in plugins and pages needs to be changed, though the change is rather small. Benefit: A single text can be accessed as well: $('.asdf').text()[42]; the texts can be joined differently as well: '['+$('.asdf').text().join('][')+']';
Links on wiki frontpage
Hi, I guess John is the only one who can do something about these, but perhaps they are worth a bit discussion, so: Shouldn't the front page link to the new Selectors API page? http://docs.jquery.com/Selectors Currently it still points to http://docs.jquery.com/DOM/Traversing/Selectors which is utterly outdated. I also wonder if http://docs.jquery.com/Types should be on the frontpage/main navigation. There are a lot of links from the API to that page, I think it is useful to have a direct link to
Deep extend broken?
Using deep $.extend() clobbers my source objects. Example: var target = {}; var s1 = { will:{name:"Will Moffat"} }; var s2 = { will:{age:29} }; $.extend(/*deep*/true,target,s1,s2); // OK: target = { will:{name:"Will Moffat", age:29} } // FAIL: s1 = { will:{name:"Will Moffat", age:29} } // OK: s2 not modified s1 has been modified, it's now the same as target. Is this a feature or a bug? regards, --Will
Documentation of traversing/end()
This is undoubtedly the wrong place to raise this, but ... aren't nextAll, prevAll, andSelf, map and slice also 'destructive' operations that can be reverted by end()?
Wierd IE bug with remove()/Safari bug with width()
Hi, First of all, thanks a lot for a great framework! I've only just begun using jQuery, but I love it already! Anyway, I'm developing an object for making lists sortable, and I have found a wierd bug in IE with remove(). The way I do it is that on mousedown on a listitem, I clone the listitem, give the clone 0 opacity and insert it into the list right before the element clicked on, which is then absolutely positioned to follow the mouse. I call that clone a "dummy", and I move the dummy if you hover
Next Page