Heyvaert / wiquery

Automatically exported from code.google.com/p/wiquery
0 stars 0 forks source link

wiQuery Dialog - null obj jQuery error #267

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
I have a simple wiQuery Dialog window:

Java code:

final Dialog dialog = new Dialog("dialog");
        add(dialog);
add(new WebMarkupContainer("wiquery").add(new WiQueryEventBehavior(new 
Event(MouseEvent.CLICK) {
            private static final long serialVersionUID = 1L;

            @Override
            public JsScope callback()
            {
                return JsScope.quickScope(dialog.open().render());
            }

        })));

HTML markup:

<p wicket:id="dialog">Popup modal window</p>
<a wicket:id="wiquery">Dialog</a>

Each time I try I receive an error:
Cannot read the property 'length' of undefined.

Temporarily I figured out this problem by changing jQuery script source 
(v1.9.1):

Line 622 from length = obj.length, to length = obj ? obj.length : 0,
Line 952 from var length = obj.length, to var length = obj ? obj.length : 0,
Line 959 from if ( obj.nodeType === 1 && length ) { to if ( obj && obj.nodeType 
=== 1 && length ) {

Original issue reported on code.google.com by toudidel on 6 Apr 2013 at 8:44

GoogleCodeExporter commented 9 years ago
Wicket version 6.6.0
wiQuery version 6.6.0

Original comment by toudidel on 6 Apr 2013 at 8:48

GoogleCodeExporter commented 9 years ago
this issue has been fixed in jquery since wicket 6.9+

Original comment by hielke.hoeve on 26 Nov 2013 at 8:46

GoogleCodeExporter commented 9 years ago

Original comment by hielke.hoeve on 26 Nov 2013 at 8:46

GoogleCodeExporter commented 9 years ago
Thx for fixing

Original comment by toudidel on 26 Nov 2013 at 8:58