Thanks for the link and comments Julian.

I read completely the post, and realized that in my case it is ok to use the
iframes. Some of the comments say that it is not good practice to use them
as site navigation, which is not the case. I am using iframes only to popup
information on demand.

"If you are using it to simply embed a page inside your content, I think
that is fine. That is what an iframe is for."  Adzm

Brian mentioned that "iframe cause noticeable slowdown in the speed your
page downloads". Again, in my case the iframe will only load when the user
click in the map requesting information about the layer. They will not load
"on map load".

I believe that the only issue that can affect me is the possibility that it
might fail for some browsers. I tested so far with the major browsers and it
worked. I've noticed some problems with the iphone but it is related with
zooming, not the popups. Therefore, so far so good.

As for just writing javascript code let me explain that I am an engineer who
is programming for necessity. Therefore, I am looking first for simple
solutions. If I don't find then I will have to write code.

Cheers.

JJ.



 -----Original Message-----
From: Julian Hollingbery [mailto:jul...@northtech.dk] 
Sent: Tuesday, November 17, 2015 12:19 AM
To: Jair Santos <jsantos5...@gmail.com>; 'GeoServer Mailing List List'
<geoserver-users@lists.sourceforge.net>
Subject: SV: [Geoserver-users] Links from WMS

Hi Jair,

While I would generally discourage the use of iframes (see e.g.
http://stackoverflow.com/questions/362730/are-iframes-considered-bad-practic
e), shouldn't you simply use Javascript to manipulate the info_reservoir
into a link?

Regards,
Julian
________________________________________
Fra: Jair Santos [jsantos5...@gmail.com]
Sendt: 16. november 2015 22:24
Til: 'GeoServer Mailing List List'
Emne: [Geoserver-users] Links from WMS

Hello all,

I am requesting information from Geoserver in a popup overlay using WMS as
source for a <iframe>

http://192.168.1.111:8080/geoserver/wms?SERVICE=WMS&VERSION=1.3.0&REQUEST=Ge
tFeatureInfo&FORMAT=image%2Fpng&TRANSPARENT=true&QUERY_LAYERS=bmid_reserv&LA
YERS=bmid_reserv&INFO_FORMAT=text%2Fhtml&I=228&J=206&WIDTH=256&HEIGHT=256&CR
S=EPSG%3A3857&STYLES=&BBOX=-13284144.019737352%2C6430800.063688448%2C-132838
38.271624211%2C6431105.811801588

Parts of the information are links to pdf documents, so the user can
download them from the popup. The data is coming from Postgres that do not
support links as datatypes and Geoserver sends the information as plain
text. Is there a way that geoserver can provide them as links?

info_reservoir = wms_bmid_reservoir.getGetFeatureInfoUrl(
    evt.coordinate, viewResolution, 'EPSG:3857',
    { 'INFO_FORMAT': 'text/html' })
content.innerHTML = '<iframe seamless src="' + info_reservoir +
'"></iframe>'; overlay.setPosition(coordinate);

Thanks in advance for any ideas.

JJ.


------------------------------------------------------------------------------
_______________________________________________
Geoserver-users mailing list
Geoserver-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geoserver-users

Reply via email to