问题
http://auteli.com/login.php
login: Autelek pass: Autelek123
Go to My Geographical Apps
Now i have a couple of dropdown menus and a problem with the z-index, the dropdowns are hiding each other. I've tried z-index !important, change the z-index with javascript but still nothing. I believe it's the having multiple forms.
回答1:
When I clicked in Add (Available Areas), others combos had try to reload, but they fail.
If you want reload these combos, you need to reset select container style and contents before it (div container -> remove class jqTransformSelectWrapper and delete the two childs before select it self).
I've made a function for jqTransform. Something like this:
$.fn.jqTransSelectReset = function () {
this.each(function () {
var item = $(this);
if (item.hasClass('jqTransformHidden')) {
item.removeClass('jqTransformHidden');
$(item.parent().get(0)).removeAttr('style');
$(item.parent().get(0)).removeAttr('class');
$(item.parent().get(0, 'children').firstChild).remove(); // div
$(item.parent().get(0, 'children').firstChild).remove(); // ul
}
});
// this class is just a flag - remove it
$('select').removeClass('jqTransformHidden');
// re-run the transformation in all selects
return $('select').jqTransSelect();
};
Then you load your combobox and call the function jqTransSelectReset like this:
$('#yourSelectToRefresh').load(...); // fake method to load combobox
$('select').jqTransSelectReset();
Hope it helps!
Best Regards.
Remember: if it helps you, vote up! =)
来源:https://stackoverflow.com/questions/9515161/jquery-jqtransform-multiple-forms-on-same-page-z-index