javascript - Replacment infoBox to jquery dialog modal window -
here have map, markers , infoboxes.
now want change infoboxes jquery dialog() , modal window... how can that?
here code infobox
 google.maps.event.addlistener(marker,'click',function(){          service.getdetails(request, function(place, status) {           if (status == google.maps.places.placesservicestatus.ok) {             var contentstr = '<div class="m_tooltip"><h5>'+place.name+'</h5><p>'+place.formatted_address+'</p>';             if (!!place.formatted_phone_number) contentstr += '<br>'+place.formatted_phone_number;             if (!!place.website) contentstr += '<br><a target="_blank" href="'+place.website+'">'+place.website+'</a>';             if (!!place.photos) contentstr += '<img src='+place.photos[0].geturl({ 'maxwidth': 300, 'maxheight': 300 })+'></img>';             contentstr += '<br>'+place.types+'</p>';               //contentstr += '<h5">'+place.reviews[0].text+'</h5></div>';             ib.setcontent(contentstr);             ib.open(map,marker);            } else {              var contentstr = "<h5>no result, status="+status+"</h5>";             ib.setcontent(contentstr);             ib.open(map,marker);           }         });      });  gmarkers.push(marker);   now want change dialog...
i try with:
$(function() {     $( ".m_tooltip" ).dialog({       resizable: false,       height:140,       modal: true     });   });   but dont work... please help
google.maps.event.addlistener(marker,'click',function(){       service.getdetails(request, function(place, status) {       var content= '<h1>'+place.name+'</h1>';//and add want       $(content).dialog();       });       });      
Comments
Post a Comment