I am trying to figure out how to get my entities (or kmls or any other geo footprint i might have) to open when a link is pressed.
The idea here is that one could click on a warped section on the cesium JS map and it would open up a dialog there where you could click on the deep zoom viewer link, popping up a new window/tab to show the warped tile as a huge image you can scroll all around and get in really close etc. So this is what I came up with:
(btw the deep image viewer is openseadragon)
var entity3cesium = new Cesium.Entity();
entity3cesium.name = 'entity3';
entity3cesium.id = '3';
entity3cesium.polygon = new Cesium.PolygonGraphics({
hierarchy : Cesium.Cartesian3.fromDegreesArray([
32.8333333333,68.8863888889,
32.6125,69.1380555556,
33.8158333333,69.2675,
34.0236111111,69.0144444444,
]),
material : '../../some.nitf_warped.png',
outline:true,
outlineColor : Cesium.Color.RED
});
entity3cesium.description = '<a href=\"http://localhost:8000/static/openseadragon/deepzoomviewer.html?a=Folder&b=some.nitf.dzi\" target=\"_blank\">Deep Viewer Link</a>'; //add link to pop up into open sea dragon, which uses code on that html file to parse the above link and display the right deep zoom image.
So this will put an entity on the map with a warped png file of it (I created using gdalwarped. I wanted to use gdal2tiles but cannot get that to work right, I have another forum question on gdal2tiles and TMS stuff in another thread on here). In either case, you click on the entity in cesium and it opens up this dialog to the right with the link there, you click on that and a new window does open but I get an error in the browser because of some java script error:
Blocked script execution in 'http://localhost:8000/static/openseadragon/deepzoomviewer.html?a=Folder&b=some.nitf.dzi' because the document's frame is sandboxed and the 'allow-scripts' permission is not set.
No idea what causes this or how to resolve this. The window that is opened up does have all the javascript code for the openseadragon dzi viewer. The above link works if it is just to something like cnn.com or something. Though I think how cesium setups the link is what is causing the issue (having to do with frame and sandboxed?) maybe not but I am grasping at straws so posting here.
Is there another preferred
way to open a link from a clicked entity in cesiumjs that might work better?
dear sir these error show in my click to infobox and open new page but result are not good and show these error please help.
thanks