-
Notifications
You must be signed in to change notification settings - Fork 727
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Tabs : error javascript on refresh #289
Comments
I have tried to replicate the problem but could not. Can you see if this happens without the use of other libraries besides jQuery. About your fix, it does not seem to look correct. The parameter id can be passed as undefined and you are only checking for null. However, this.get(id) will return null or an object. |
in my case, when i had the original version var tab = this.get(id); i had values : id = null and tab = undefined Only rescue was to check on id==null |
I still have hard time replication. Can you post code sample? Is it reproducible without other libraries? |
i will try to come back to you ASAP |
i removed prototype.js and i don't have any errors now. Is hardly maintainable to keep prototype and jquery on same project. I made some library cleaning on same time. |
w2ui-1.3.js line 7267
stack :
Uncaught TypeError: Cannot read property 'id' of undefined w2ui-1.3.js:7282
w2tabs.refresh w2ui-1.3.js:7282
w2tabs.refresh w2ui-1.3.js:7261
w2tabs.render w2ui-1.3.js:7328
$j.fn.w2tabs w2ui-1.3.js:7096
(anonymous function) notifications.jsp:399
fire jquery-2.0.2.js:2939
self.fireWith jquery-2.0.2.js:3051
jQuery.extend.ready jquery-2.0.2.js:398
completed
i replaced this :
// create or refresh only one item
var tab = this.get(id);
if (tab == null) return;
by this :
// create or refresh only one item
var tab = this.get(id);
if (id == null) return;
it works fine now
i am using with prototype.js and jquery noConflict mode. I had to rename all $ on w2ui to $j. Is not a better solution for w2ui for replacing $ variable as jquery does ?
Can you send me back a comment on my fix ?
Thanks
The text was updated successfully, but these errors were encountered: