[OpenLayers-Users] Map Wont Show
Arnd Wippermann
arnd.wippermann at web.de
Thu Jul 19 10:36:12 PDT 2012
as often it's a problem with ie. With Firefox and Chrome the map looks as
expected.
What's wrong with IE?. Perhaps it has to do with fiddle. Try without fiddle.
Arnd
_____
Von: David TRACY [mailto:kurttracy at utah.gov]
Gesendet: Mittwoch, 18. Juli 2012 02:59
An: Arnd Wippermann
Cc: users at openlayers.org
Betreff: Re: AW: [OpenLayers-Users] Map Wont Show
I updated my code with the new suggestions. This time i get a white layer
over the background. Before all I could see was background.
I noticed an error in IE i might not of noticed previously.
Message: Object doesn't support this property or method
Line: 30
Char: 5
Code: 0
URI: http://fiddle.jshell.net/pBnB8/1/show/
Message: 'this.baseLayer.wrapDateLine' is null or not an object
Line: 238
Char: 276
Code: 0
URI: http://openlayers.org/dev/OpenLayers.js
Suggestions would be appreciated. Thanks for the help this far.
David "Kurt" Tracy
Emergency Management Planner II
1-801-828-8158 Cell
1-801-538-3767 Office
>>> "Arnd Wippermann" <arnd.wippermann at web.de> 07/08/2012 11:02 AM >>>
you have to add "export?f=image" to your url and the layers parameter is
somethink like "show:0,1,2".
function init(){
var mapOptions = {
maxExtent: new OpenLayers.Bounds(-174,18.4,-63.5,71),
maxResolution: 0.25,
projection: "EPSG:4326"};
map = new OpenLayers.Map( 'map', mapOptions );
layer = new OpenLayers.Layer.ArcGIS93Rest( "ArcGIS Server Layer",
"http://mapserv.utah.gov/ArcGIS/rest/services/UtahBaseMap-Hybrid/MapServer/e
xport?f=image",
{ layers: "show:0,1,2" });
map.addLayer(layer);
map.addControl( new OpenLayers.Control.MousePosition() );
map.setCenter(new OpenLayers.LonLat(-111.6, 39.3), 9);
}
window.onload = init();
Arnd
_____
Von: openlayers-users-bounces at lists.osgeo.org
[mailto:openlayers-users-bounces at lists.osgeo.org] Im Auftrag von David TRACY
Gesendet: Samstag, 7. Juli 2012 04:10
An: openlayers-users at lists.osgeo.org
Betreff: [OpenLayers-Users] Map Wont Show
I am new to open layers. Will you please verify my code is correct. Can
you give me any pointers on how to troubleshoot if the service is bad.
Here is a fiddle of the map.
http://jsfiddle.net/pBnB8/
The controls show up but nothing else.
David "Kurt" Tracy
Emergency Management Planner II
1-801-828-8158 Cell
1-801-538-3767 Office
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/openlayers-users/attachments/20120719/dde79dd2/attachment.html>
More information about the Users
mailing list