Thanks for your help and patience so far...<br><br>I´ll try to explain better my problem...<br>I have a google base and several wms overlay layers ... Everthing is working fine...<br>Relevant code:<br><br>Map<br> PROJECTION <br>
"init=epsg:900913"<br> END<br><br> METADATA<br> "wms_srs" "EPSG:4326 EPSG:900913"<br><br>Layers Wms<br>PROJECTION<br> "init=epsg:4326"<br>END<br><br>----------------------<br>
But now I need to add other base layer, so I´ll have 2 base layers:<br>- Google Base Layer : EPSG:900913<br>- WMS Base Layer : EPSG:4326<br><br>When I change to WMS Base Layer, my all layers are gone, including the others WMS layers...<br>
<br>Relevante Code:<br>My map remain the same...<br><br>WMS BASE LAYER (Original projection : 4326):<br>METADATA<br> "wms_srs" "EPSG:900913 EPSG:4326"<br> "wms_title" "TESTBASE" <br>
END <br> <br> PROJECTION<br> "init=epsg:4326"<br> END<br><br>My openlayers config:<br><br> map = new OpenLayers.Map('testt', { <br> projection: new OpenLayers.Projection("EPSG:900913"),<br>
units: "m",<br> displayProjection: new OpenLayers.Projection("EPSG:4326"),<br> tileSize: new OpenLayers.Size(400, 400), <br> numZoomLevels: 10, <br> maxExtent: new OpenLayers.Bounds(-20037508.34, -20037508.34, 20037508.34, 20037508.34)<br>
<br> var googleBaseLayer = new OpenLayers.Layer.Google(<br> "Google Streets",<br> {'sphericalMercator': true}<br> );<br><br> var wmsBaseLayer = new OpenLayers.Layer.WMS("UFBASE",<br>
GetMapFileLocation(), {<br> "LAYERS": ['UFBASE'], <br> transparent: true, <br> format: "image/png"<br>
}, { <br> isBaseLayer: true, <br> displayInLayerSwitcher: true <br> });<br><br>So, Am I missing something?<br>
<br><div class="gmail_quote">On Wed, Aug 18, 2010 at 11:39 AM, David Fawcett <span dir="ltr"><<a href="mailto:david.fawcett@gmail.com">david.fawcett@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">
Your layer projection block should reflect the spatial reference<br>
system of the data that the layer is based on (input projection). The<br>
projection block at the map level sets the output projection when your<br>
application receives a normal MapServer request. For WMS requests,<br>
this is handled by the layer wms_srs metadata.<br>
<br>
I don't totally understand your problem, but I think that there are<br>
two potential areas to look at:<br>
<br>
1. Is OpenLayers sending the correct WMS request to your MapServer<br>
app to get the layer that it needs.<br>
<br>
2. If the WMS request is correct, is your MapServer app configured to<br>
return the correct layer?<br>
<br>
You can use FireBug to look at the WMS request.<br>
<font color="#888888"><br>
David.<br>
</font><div><div></div><div class="h5"><br>
On Wed, Aug 18, 2010 at 9:18 AM, Paul james <<a href="mailto:pauljame@gmail.com">pauljame@gmail.com</a>> wrote:<br>
> Thanks!<br>
><br>
> Yes, i tried my layer two ways :<br>
> PROJECTION<br>
> "init=epsg:4326"<br>
> END<br>
><br>
> ==> Nothing appears<br>
><br>
> PROJECTION<br>
> "init=epsg:900913"<br>
> END<br>
><br>
> ==> The layer was draw, but in other location (0 0´0´´E 0 0´0´´N)<br>
><br>
> Paul<br>
><br>
> On Wed, Aug 18, 2010 at 11:08 AM, David Fawcett <<a href="mailto:david.fawcett@gmail.com">david.fawcett@gmail.com</a>><br>
> wrote:<br>
>><br>
>> Paul,<br>
>><br>
>> I don't think that it matters for this case, but I think that you want<br>
>> to drop the '+' sign from your MAP level projection block.<br>
>><br>
>> Do you have a projection block for your layer? That is definitely<br>
>> required.<br>
>><br>
>> David.<br>
>><br>
>> On Wed, Aug 18, 2010 at 9:00 AM, Paul james <<a href="mailto:pauljame@gmail.com">pauljame@gmail.com</a>> wrote:<br>
>> > Yes, My proj.4 has EPSG:900913...<br>
>> ><br>
>> > My mapfile:<br>
>> ><br>
>> > MAP<br>
>> > ...<br>
>> > PROJECTION<br>
>> > "+init=epsg:4326"<br>
>> > END<br>
>> ><br>
>> > WEB<br>
>> > IMAGEPATH '...'<br>
>> > IMAGEURL '...'<br>
>> ><br>
>> > METADATA<br>
>> > "wms_title" "WMS Server"<br>
>> > "wms_onlineresource" "..."<br>
>> > "wms_srs" "EPSG:4326 EPSG:900913 EPSG:3857"<br>
>> > "wms_feature_info_mime_type" "text/html"<br>
>> > "labelcache_map_edge_buffer" "-10"<br>
>> > END<br>
>> > END<br>
>> > ...<br>
>> ><br>
>> > LAYER<br>
>> > NAME TestBase<br>
>> > METADATA<br>
>> > "wms_srs" "EPSG:900913"<br>
>> > "wms_title" "TestBase"<br>
>> > "wms_feature_info_mime_type" "text/html"<br>
>> > END<br>
>> ><br>
>> ><br>
>> > Thanks<br>
>> ><br>
>> > Paul<br>
>> ><br>
>> ><br>
><br>
><br>
</div></div></blockquote></div><br>