[Proto-Scripty] Re: Opera and $$('.wrapper .class') seems not to work correctly
if its any help the same thing happens in google chrome !! - Original Message - From: Cyrus arianglan...@googlemail.com To: Prototype script.aculo.us prototype-scriptaculous@googlegroups.com Sent: Monday, January 12, 2009 5:27 PM Subject: [Proto-Scripty] Re: Opera and $$('.wrapper .class') seems not to work correctly Prototype 1.6.0.3 Opera 9.63 On 12 Jan., 17:30, kangax kan...@gmail.com wrote: On Jan 12, 10:37 am, Cyrus arianglan...@googlemail.com wrote: Hi there, I have found a weird behaviour in the opera browser. I am not sure if this is really a bug or an intended behaviour. [...] Which versions of Prototype.js and Opera? -- kangax --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Prototype script.aculo.us group. To post to this group, send email to prototype-scriptaculous@googlegroups.com To unsubscribe from this group, send email to prototype-scriptaculous+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/prototype-scriptaculous?hl=en -~--~~~~--~~--~--~---
[Proto-Scripty] Re: Opera and $$('.wrapper .class') seems not to work correctly
2009/1/13 Alex Mcauley webmas...@thecarmarketplace.com: if its any help the same thing happens in google chrome !! - Original Message - From: Cyrus arianglan...@googlemail.com To: Prototype script.aculo.us prototype-scriptaculous@googlegroups.com Sent: Monday, January 12, 2009 5:27 PM Subject: [Proto-Scripty] Re: Opera and $$('.wrapper .class') seems not to work correctly Prototype 1.6.0.3 Opera 9.63 On 12 Jan., 17:30, kangax kan...@gmail.com wrote: On Jan 12, 10:37 am, Cyrus arianglan...@googlemail.com wrote: Hi there, I have found a weird behaviour in the opera browser. I am not sure if this is really a bug or an intended behaviour. [...] Which versions of Prototype.js and Opera? -- kangax Adding ... test.each(function(el){el.style.backgroundColor='green';}); to the script (just after the var test line) and I see 2 green divs. Using Windows XP Pro SP3 with Chrome V1.0.154.43, Firefox V3.0.5 and IE V7.0.5730.13. NFF/Picnic? -- - Richard Quadling Zend Certified Engineer : http://zend.com/zce.php?c=ZEND002498r=213474731 Standing on the shoulders of some very clever giants! --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Prototype script.aculo.us group. To post to this group, send email to prototype-scriptaculous@googlegroups.com To unsubscribe from this group, send email to prototype-scriptaculous+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/prototype-scriptaculous?hl=en -~--~~~~--~~--~--~---
[Proto-Scripty] Re: Opera and $$('.wrapper .class') seems not to work correctly
Not in Opera 9.63 I am afraid ... On 13 Jan., 10:41, Richard Quadling rquadl...@googlemail.com wrote: 2009/1/13 Alex Mcauley webmas...@thecarmarketplace.com: if its any help the same thing happens in google chrome !! - Original Message - From: Cyrus arianglan...@googlemail.com To: Prototype script.aculo.us prototype-scriptaculous@googlegroups.com Sent: Monday, January 12, 2009 5:27 PM Subject: [Proto-Scripty] Re: Opera and $$('.wrapper .class') seems not to work correctly Prototype 1.6.0.3 Opera 9.63 On 12 Jan., 17:30, kangax kan...@gmail.com wrote: On Jan 12, 10:37 am, Cyrus arianglan...@googlemail.com wrote: Hi there, I have found a weird behaviour in the opera browser. I am not sure if this is really a bug or an intended behaviour. [...] Which versions of Prototype.js and Opera? -- kangax Adding ... test.each(function(el){el.style.backgroundColor='green';}); to the script (just after the var test line) and I see 2 green divs. Using Windows XP Pro SP3 with Chrome V1.0.154.43, Firefox V3.0.5 and IE V7.0.5730.13. NFF/Picnic? -- - Richard Quadling Zend Certified Engineer :http://zend.com/zce.php?c=ZEND002498r=213474731 Standing on the shoulders of some very clever giants! --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Prototype script.aculo.us group. To post to this group, send email to prototype-scriptaculous@googlegroups.com To unsubscribe from this group, send email to prototype-scriptaculous+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/prototype-scriptaculous?hl=en -~--~~~~--~~--~--~---
[Proto-Scripty] Re: Opera and $$('.wrapper .class') seems not to work correctly
I just used .class for this example. In my case I have a much more complex HTML structure so it took me a while to actually find the bug. If you're getting back one element, not two, it's a bug. The question is, in what -- Prototype's selection code, Opera, or both? I lean toward Opera bug. I guess the same, but maybe Prototype need an internal Opera workarround here? What would you suggest? File a bug report at Opera, Prototype or both? On 13 Jan., 11:35, T.J. Crowder t...@crowdersoftware.com wrote: Hi, I am not sure if this is really a bug or an intended behaviour. If you're getting back one element, not two, it's a bug. The question is, in what -- Prototype's selection code, Opera, or both? I lean toward Opera bug. Interestingly, this _doesn't_ fail on Opera 9.10 for Windows: It returns two elements as expected. Have you tried it using a different classname than class for the inner element? (I tend to think you just used that in your example, having seen this in something else, but just in case...) -- T.J. Crowder tj / crowder software / com Independent Software Engineer, consulting services available On Jan 12, 3:37 pm, Cyrus arianglan...@googlemail.com wrote: Hi there, I have found a weird behaviour in the opera browser. I am not sure if this is really a bug or an intended behaviour. The following example shows that the $$ function only returns one element instead of two. This is only because the second element is in a different dom level. All other browser return two elements with this example. ?xml version=1.0 encoding=UTF-8? !DOCTYPE html PUBLIC -//W3C//DTD XHTML 1.1//EN http://www.w3.org/ TR/xhtml11/DTD/xhtml11.dtd html xmlns=http://www.w3.org/1999/xhtml; dir=ltr xml:lang=de head meta http-equiv=Content-Type content=text/html; charset=utf-8 / titleTest/title script src=jsLib/prototype.js type=text/javascript/script script type=text/javascript //![CDATA[ function init() { // init more information handling var test = $$('.wrapper .class'); } // when the dom is fully loaded, execute these scripts document.observe(dom:loaded, init); //]] /script /head body div class=wrapper a href=# class=classtest/a /div div div class=wrapper a href=# class=classtest/a /div /div /body /html --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Prototype script.aculo.us group. To post to this group, send email to prototype-scriptaculous@googlegroups.com To unsubscribe from this group, send email to prototype-scriptaculous+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/prototype-scriptaculous?hl=en -~--~~~~--~~--~--~---
[Proto-Scripty] Re: Opera and $$('.wrapper .class') seems not to work correctly
On Jan 13, 6:26 am, Cyrus arianglan...@googlemail.com wrote: [...] What would you suggest? File a bug report at Opera, Prototype or both? I can confirm this with 9.61 on Mac OSX. Here's a minimal failing test case: !DOCTYPE html PUBLIC -//W3C//DTD HTML 4.01//EN http://www.w3.org/TR/html4/strict.dtd; html head title/title script src=http://ajax.googleapis.com/ajax/libs/prototype/ 1.6.0.3/prototype.js type=text/javascript/script /head body div class=wrapper a href=# class=classtest/a /div div div class=wrapper a href=# class=classtest/a /div /div script type=text/javascript document.write($$('.wrapper .class').length); /script /body /html Should write 2 but writes 1. This looks like an Opera bug. Moreover, I think we already have a similar ticket filed (which was essentially due to a bug in Opera's XPath engine bug and the way it handles descendant selectors). For example, switching to child selector ('.wrapper .class') returns proper result - 2. [...] -- kangax --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Prototype script.aculo.us group. To post to this group, send email to prototype-scriptaculous@googlegroups.com To unsubscribe from this group, send email to prototype-scriptaculous+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/prototype-scriptaculous?hl=en -~--~~~~--~~--~--~---
[Proto-Scripty] Re: Opera and $$('.wrapper .class') seems not to work correctly
Hi Juriy, That inline script could muddy the water in terms of DOM availability, etc. Perhaps a minor mod: !DOCTYPE html PUBLIC -//W3C//DTD HTML 4.01//EN http://www.w3.org/TR/html4/strict.dtd; html head title/title script src=http://ajax.googleapis.com/ajax/libs/prototype/ 1.6.0.3/prototype.js type=text/javascript/script script type=text/javascript document.observe('dom:loaded', function() { $('matchcount').update('Matches: ' + $$ ('.wrapper .inner').length); }); /script /head body div class=wrapper a href=# class=innertest/a /div div div class=wrapper a href=# class=innertest/a /div /div div id='matchcount'/div /body /html I also changed class to inner, again for clear water. FWIW, -- T.J. On Jan 13, 1:20 pm, kangax kan...@gmail.com wrote: On Jan 13, 6:26 am, Cyrus arianglan...@googlemail.com wrote: [...] What would you suggest? File a bug report at Opera, Prototype or both? I can confirm this with 9.61 on Mac OSX. Here's a minimal failing test case: !DOCTYPE html PUBLIC -//W3C//DTD HTML 4.01//EN http://www.w3.org/TR/html4/strict.dtd; html head title/title script src=http://ajax.googleapis.com/ajax/libs/prototype/ 1.6.0.3/prototype.js type=text/javascript/script /head body div class=wrapper a href=# class=classtest/a /div div div class=wrapper a href=# class=classtest/a /div /div script type=text/javascript document.write($$('.wrapper .class').length); /script /body /html Should write 2 but writes 1. This looks like an Opera bug. Moreover, I think we already have a similar ticket filed (which was essentially due to a bug in Opera's XPath engine bug and the way it handles descendant selectors). For example, switching to child selector ('.wrapper .class') returns proper result - 2. [...] -- kangax --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Prototype script.aculo.us group. To post to this group, send email to prototype-scriptaculous@googlegroups.com To unsubscribe from this group, send email to prototype-scriptaculous+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/prototype-scriptaculous?hl=en -~--~~~~--~~--~--~---
[Proto-Scripty] Re: Opera and $$('.wrapper .class') seems not to work correctly
Ok, thanks. Unfortunately I cannot use the child selector in my case. I'll write a bug report. On 13 Jan., 14:20, kangax kan...@gmail.com wrote: On Jan 13, 6:26 am, Cyrus arianglan...@googlemail.com wrote: [...] What would you suggest? File a bug report at Opera, Prototype or both? I can confirm this with 9.61 on Mac OSX. Here's a minimal failing test case: !DOCTYPE html PUBLIC -//W3C//DTD HTML 4.01//EN http://www.w3.org/TR/html4/strict.dtd; html head title/title script src=http://ajax.googleapis.com/ajax/libs/prototype/ 1.6.0.3/prototype.js type=text/javascript/script /head body div class=wrapper a href=# class=classtest/a /div div div class=wrapper a href=# class=classtest/a /div /div script type=text/javascript document.write($$('.wrapper .class').length); /script /body /html Should write 2 but writes 1. This looks like an Opera bug. Moreover, I think we already have a similar ticket filed (which was essentially due to a bug in Opera's XPath engine bug and the way it handles descendant selectors). For example, switching to child selector ('.wrapper .class') returns proper result - 2. [...] -- kangax --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Prototype script.aculo.us group. To post to this group, send email to prototype-scriptaculous@googlegroups.com To unsubscribe from this group, send email to prototype-scriptaculous+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/prototype-scriptaculous?hl=en -~--~~~~--~~--~--~---
[Proto-Scripty] Re: Opera and $$('.wrapper .class') seems not to work correctly
On Jan 13, 8:30 am, T.J. Crowder t...@crowdersoftware.com wrote: Hi Juriy, That inline script could muddy the water in terms of DOM availability, etc. Perhaps a minor mod: I usually try to eliminate as much of irrelevant prototypeism as possible when creating a testcase : ) Why use dom:loaded (which is also known to be unreliable in IE in its current implementation) when we can simply run script at the time when body is definitely loaded and parsed. [...] -- kangax --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Prototype script.aculo.us group. To post to this group, send email to prototype-scriptaculous@googlegroups.com To unsubscribe from this group, send email to prototype-scriptaculous+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/prototype-scriptaculous?hl=en -~--~~~~--~~--~--~---
[Proto-Scripty] Re: Opera and $$('.wrapper .class') seems not to work correctly
I usually try to eliminate as much of irrelevant prototypeism as possible when creating a testcase : ) Fair 'nuff, but I'd still use something other than inline to allow for browsers being difficult about the closing body tag and DOM rendering time. Probably me being paranoid. Perhaps (shock and horror) DOM0 window.onload stuff, image loading not being an issue: script type='text/javascript' window.onload = function() { alert('Found ' + $$('.wrapper .inner').length); }); /script at the time when body is definitely loaded and parsed. Is it, definitely? Within the tag? (Serious question, you know more about this stuff than I do.) -- T.J. ;-) On Jan 13, 2:17 pm, kangax kan...@gmail.com wrote: On Jan 13, 8:30 am, T.J. Crowder t...@crowdersoftware.com wrote: Hi Juriy, That inline script could muddy the water in terms of DOM availability, etc. Perhaps a minor mod: I usually try to eliminate as much of irrelevant prototypeism as possible when creating a testcase : ) Why use dom:loaded (which is also known to be unreliable in IE in its current implementation) when we can simply run script at the time when body is definitely loaded and parsed. [...] -- kangax --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Prototype script.aculo.us group. To post to this group, send email to prototype-scriptaculous@googlegroups.com To unsubscribe from this group, send email to prototype-scriptaculous+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/prototype-scriptaculous?hl=en -~--~~~~--~~--~--~---
[Proto-Scripty] Re: Opera and $$('.wrapper .class') seems not to work correctly
Hey all, when you're replying to these threads, can you make sure you keep it on-list? I like to keep up with various solutions to all these problems, and seeing half the solution (or no solution at all) is really frustrating. (@Kangax, I know I've seen a few replies to messages you've sent off-list, and since I know you've got good replies, I'd love it if they'd stay on the list. :-D) Thanks! On Tue, Jan 13, 2009 at 12:58 PM, T.J. Crowder t...@crowdersoftware.comwrote: I usually try to eliminate as much of irrelevant prototypeism as possible when creating a testcase : ) Fair 'nuff, but I'd still use something other than inline to allow for browsers being difficult about the closing body tag and DOM rendering time. Probably me being paranoid. Perhaps (shock and horror) DOM0 window.onload stuff, image loading not being an issue: script type='text/javascript' window.onload = function() { alert('Found ' + $$('.wrapper .inner').length); }); /script at the time when body is definitely loaded and parsed. Is it, definitely? Within the tag? (Serious question, you know more about this stuff than I do.) -- T.J. ;-) On Jan 13, 2:17 pm, kangax kan...@gmail.com wrote: On Jan 13, 8:30 am, T.J. Crowder t...@crowdersoftware.com wrote: Hi Juriy, That inline script could muddy the water in terms of DOM availability, etc. Perhaps a minor mod: I usually try to eliminate as much of irrelevant prototypeism as possible when creating a testcase : ) Why use dom:loaded (which is also known to be unreliable in IE in its current implementation) when we can simply run script at the time when body is definitely loaded and parsed. [...] -- kangax -- Jerod Venema Frozen Mountain Software http://www.frozenmountain.com/ 919-368-5105 --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Prototype script.aculo.us group. To post to this group, send email to prototype-scriptaculous@googlegroups.com To unsubscribe from this group, send email to prototype-scriptaculous+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/prototype-scriptaculous?hl=en -~--~~~~--~~--~--~---
[Proto-Scripty] Re: Opera and $$('.wrapper .class') seems not to work correctly
On Jan 12, 10:37 am, Cyrus arianglan...@googlemail.com wrote: Hi there, I have found a weird behaviour in the opera browser. I am not sure if this is really a bug or an intended behaviour. [...] Which versions of Prototype.js and Opera? -- kangax --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Prototype script.aculo.us group. To post to this group, send email to prototype-scriptaculous@googlegroups.com To unsubscribe from this group, send email to prototype-scriptaculous+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/prototype-scriptaculous?hl=en -~--~~~~--~~--~--~---