On Thu, Nov 11, 2010 at 6:02 AM, x_tls_x <[email protected]> wrote:
>
> Hi list,
> Hi friends,
>
> i tried do use the ol popup functionality with jQuery ui tabs. But i dont
> worked. JQuery ajax works very well with ol.
>
> I use:
> (JQuery tab)
> $(function() {
>        $("#tabs").tabs({
>                                cookie: {
>                                        // store cookie for a day, without, it 
> would be a session cookie
>                                        expires: 1
>                                }
>                        });
>                });


When the above tab initialization code runs, the tab making code below
is not available in the DOM. It is just a code fragment inside the ol
popup code.

Try creating the tabs panels, and after that run the jQuery tab init
code again. There might be a callback in the ol popup call that might
run after the popup has been displayed. Try using that.


> (and ol popup)
> function onFeatureSelect(feature) {
> popup = new OpenLayers.Popup.FramedCloud("popup",
>                        feature.geometry.getBounds().getCenterLonLat(),
>                    null,
>                    "<div id='tabs'>"+
>                    "<ul> <li> #tabs-1 Nodes </li> " +
>                    "<li> #tabs-2 Clients </li> " +
>                    "<li> #tabs-3 NMS </li> </ul>" +
>                    "<div id='tabs-1'>" +
>                            "<p>14 Nodes active</p>" +
>                            "<p>1 new Node</p>" +
>                    "</div>" +
>                    "<div id='tabs-2'>" +
>                            "<p>15 Clients</p>" +
>                            "<p>2 Rogues</p>" +
>                    "</div>" +
>                    "<div id='tabs-3'>" +
>                            "<p>2 Users online</p>" +
>                            "<p>Server OK</p>" +
>                    "</div>",
>            null, true, onPopupClose);
>            feature.popup = popup;
>            map.addPopup(popup);
>    }
>
> I dont know why it dont worked. Have anyone an idea?
>


> Thanks a lot for any advise,
> x_tls_x
> --
> View this message in context: 
> http://osgeo-org.1803224.n2.nabble.com/OpenLayer-popup-and-jQuery-ui-tabs-tp5728435p5728435.html
> Sent from the OpenLayers Users mailing list archive at Nabble.com.
> _______________________________________________
> Users mailing list
> [email protected]
> http://lists.osgeo.org/mailman/listinfo/openlayers-users
>



-- 
Puneet Kishor http://www.punkish.org
Carbon Model http://carbonmodel.org
Charter Member, Open Source Geospatial Foundation http://www.osgeo.org
Science Commons Fellow, http://sciencecommons.org/about/whoweare/kishor
Nelson Institute, UW-Madison http://www.nelson.wisc.edu
-----------------------------------------------------------------------
Assertions are politics; backing up assertions with evidence is science
=======================================================================
_______________________________________________
Users mailing list
[email protected]
http://lists.osgeo.org/mailman/listinfo/openlayers-users

Reply via email to