I have a table in a jsp, this jsp is shown is several contentPanes that are included in a TabContainer, so I get a widget Id collision with the id of the table, how could I avoid this widget ID collision?
This is the code for the table:
I have a table in a jsp, this jsp is shown is several contentPanes that are included in a TabContainer, so I get a widget Id collision with the id of the table, how could I avoid this widget ID collision?
This is the code for the table:
let dojo decide
Hi joseiru
When I look into the DOM in Firebug, I can see a lot of widget ids like this:
FloatingPane_0,FloatingPane_1,FilteringTable_0,Form_0 and so on.
So it seems as if dojo sets the widget's ids automatically by increasing an internal counter for each class.
So you should remove the id from your .jsp source and see what dojo makes off it.
Perhaps that helps.
Path
I rescue this, because I
I rescue this, because I continue having these collisions, I create tabs on demand, in these tabs I show a jsp that includes dojo comboboxes, a filtering table, dropdowndatepickers, and I get an id collision with all of them, because I create different tabs with the same jsp.
Related to this, I have document.form inside these jsp, and I also have problems with the id collision and I do not know how could I control the number of the item form in the document.forms[]
Can anyone give another idea of how to avoid these? It is important for me, and I would appreciate very much all your help.
Thank you!
J.
Avoid using widgetIds by: 1.
Avoid using widgetIds by:
1. Using dojoAttachPoints to get element/object references: http://dojotoolkit.org/forum/dojoattachpoint-getting-widgets-instead-nod...
2. Use combinatorial widgetIds in cases where you really need widgetIds: http://dojotoolkit.org/forum/trying-create-menus-my-own-widget
I have a Main.jsp where I
I have a Main.jsp where I have a Tab, In this Tab I have a ContentPane with Tab.jsp
In this Tab.jsp I have several widgets, for example doing the AttachPoint solution:
But when I try to access to the widget in the javascript file:
I get an undefined value.
What could it be the problem.
For the other solution, I do not know how to access the widget in the javascript, could you give an example for this?
Thanks a lot!
J.
Did you got a solution?
Hi Joseiru,
we're having exactly the same problem but we're using Struts 2.0.11 + DOJO Plugin.
We have to create a webpage with a tree which opens new tabs depending on the selected action.
I think that our problem is even worse because we "don't control" the generated html tags (we're using struts-tags).
Did you got a solution? Do you know any patch or similar?
Our main problem is that we're getting cross AJAX calls (you click in one Tab button but the result is shown in other tab).
Thank you very much.