I'm using OpenLayer.Popup.FramedCloud from OpenLayer (JavaScript Mapping Library). in the popup constructor there is a parameter called contentHTML. I put there html button with onlick event:
contentHTML = "<button type='button' onclick='alert()'>Hello</button>";
from some reason the button doesn't respond to a click. Why? Is there a solution for this?
Maybe this is because the web page is uploaded in Winform WebBrowser? I noticed that when I upload the page with a regular browser (chrome) everything's working but not in Winform WebBrowser.
the complete popup object:
var lonlat = new OpenLayers.LonLat(lon, lat);
var size = new OpenLayers.Size(300,200)
var htmlString = "<button type='button' onclick='alert()'>Hello</button>";
popup = new OpenLayers.Popup.FramedCloud("popup",
lonlat,
size,
htmlString,
anchor=null,
closeButtonX =false);
popup.id = callId;
g_waze_map.map.addPopup(popup);
thanks a lot.