Issue with jQuery ui tabs -
i've following jquery code,
$("#tabs").tabs({ select: function(event, ui) { window.location.replace(ui.tab.hash); },}).addclass( "ui-tabs-vertical ui-helper-clearfix" ); except first tab other tabs jquery adding style attribute value display:none,due i'm getting error while loading openlayers map in second tab.because while creating map corresponding div in hidden state.so added below code,
$("#tabs").tabs("widget").find('#tab-2').attr('style','display:block'); but leads problem,while loading third tab,second tab in visible state,is there alternate solution issue?
i had similar problem not using jqueryui. because control the way tabs worked set width , height 0 rather using display: none hide tabs allowed map - gmaps in case render.
the other thing @ callback. i.e render map on click of tab rather when page loads. there method doing think: http://api.jqueryui.com/tabs/#event-activate
update: ended doing second of these ideas said wrote own tabs bit easier.
Comments
Post a Comment