<html>
<head>
<style>
.hmmessage P
{
margin:0px;
padding:0px
}
body.hmmessage
{
FONT-SIZE: 10pt;
FONT-FAMILY:Tahoma
}
</style>
</head>
<body class='hmmessage'><div style="text-align: left;">Hi!<br><br>I provide you my OpenLayers code.<br><br><pre class="alt2" style="border: 1px inset ; margin: 0px; padding: 6px; overflow: auto; width: 640px; height: 498px;">function init()<br>        {<br>            OpenLayers.DOTS_PER_INCH = 72;<br>            <br>            // --------------------------------------------------------------------------//<br>            // Tableau des options pour la carte.                                          //<br>            // La plus importante est scales qui permet de definir les différents zooms  //<br>            // qui seront disponibles pour l'utilisateur.                                //<br>            // --------------------------------------------------------------------------//<br>            <br>            var options = <br>            {<br>                 scales: [3500000, 3000000,2500000,2000000,1500000,1000000,350000,250000],<br>                 maxScale: 250000,<br>                 minScale: 3500000,<br>                 controls: [new OpenLayers.Control.MouseDefaults()]<br>            };<br>             <br>            // -------------------------//<br>            // Création de l'objet map. //<br>            // -------------------------//<br>                          <br>            map = new OpenLayers.Map( 'map',options);<br>            <br>            // ----------------------------------------------//<br>            // On ajoute les couches après les avoir créées. //<br>            // ----------------------------------------------// <br>            <br>            layer = new OpenLayers.Layer.MapServer( "OpenLayers WMS", <br>                    "http://localhost/cgi-bin/mapserv?mode=map&amp;map=/var/www/html/ms/map_files/france.map", {layers: ['FRANCE','CORSE']},<br>                    {gutter: 0    });<br>                        <br>            map.addLayer(layer);<br>                     <br>            <br>        }<br><br>            // -----------------------------------------------------------------------//<br>            // Ajout de la barre de zoom et des coordonnées de la position actuelle.  //<br>            // -----------------------------------------------------------------------//<br>          <br>            map.addControl( new OpenLayers.Control.PanZoomBar() );<br>            <br>            // ------------------------------//<br>            // Ajout de la gestion du click. //<br>            // ------------------------------//<br>           <br>               var click = new OpenLayers.Control.Click();<br>                map.addControl(click);<br>                click.activate();<br>            <br>            // ---------------------------------------------------------------------------//<br>              // Et on définit le centre de notre carte, afin qu'elle sot bien positionnée. //<br>              // ---------------------------------------------------------------------------//<br>              <br>            map.setCenter(new OpenLayers.LonLat(lon, lat), zoom);</pre><br><br>And my mapfile has the good projections block, one for the map and one for each layer. Consequently, it works with mapserver &amp; without OL.<br><br>Regards.<br><br>Clement<br></div><br><br><br><hr id="stopSpelling">&gt; Date: Tue, 29 Apr 2008 15:43:32 -0400<br>&gt; From: jlacroix@mapgears.com<br>&gt; To: clems_mars@hotmail.com<br>&gt; CC: mapserver-users@lists.osgeo.org<br>&gt; Subject: Re: [mapserver-users] OpenLayers &amp; Projection<br>&gt; <br>&gt; Hi,<br>&gt; <br>&gt; You can take a look at how projection are set in OpenLayers:<br>&gt; <br>&gt; http://trac.openlayers.org/wiki/FrequentlyAskedQuestions#Projections<br>&gt; <br>&gt; Or at the Source of the OpenLayers projection example:<br>&gt; http://www.openlayers.org/dev/examples/projected-map.html<br>&gt; <br>&gt; You will also need to define the PROJECTION block at the layer level and <br>&gt; at the map level in your mapfile.<br>&gt; <br>&gt; Julien<br>&gt; <br>&gt; PS: Please provide revelent mapfile part and revelent code when asking a <br>&gt; question it will help us figuring out what may be your problem.<br>&gt; <br>&gt; Clemiou wrote:<br>&gt; &gt; Hi all!<br>&gt; &gt;  <br>&gt; &gt; I come back here because I always have the same problem.<br>&gt; &gt; So, I have a .ewc file which represent the France. This file is in Lambert II (French position, centered on France).<br>&gt; &gt; Currently, I display this map with WGS84 projection but naturally, my map is distorded because this projection is centered on the equator.<br>&gt; &gt; So, if I try to displaying my map with the Lambert II projection, I obtain the following figure:<br>&gt; &gt;  <br>&gt; &gt; http://www.forumsig.org/attachment.php?attachmentid=2286&amp;stc=1&amp;d=1208951661 &lt;http://www.forumsig.org/attachment.php?attachmentid=2286&amp;stc=1&amp;d=1208951661&gt;<br>&gt; &gt;  <br>&gt; &gt; As you can see, there is a malfunction=&gt; the repetition of a part of each tile.<br>&gt; &gt;  <br>&gt; &gt; I tried to add projection and units options to my map but nothing change. I think that is a OpenLayers probleme because my map is correctly display with Mapserver and without OL.<br>&gt; &gt; Perhaps someone here should help me.<br>&gt; &gt; <br>&gt; &gt; Thanks for your futur help and once more, excuse me for my English.<br>&gt; &gt;  <br>&gt; &gt; Have a nice day<br>&gt; &gt;  <br>&gt; &gt; Clement<br>&gt; &gt; <br>&gt; &gt; <br>&gt; &gt; ------------------------------------------------------------------------<br>&gt; &gt; Plus de 15 millions de français utilisent Windows Live Messenger ! <br>&gt; &gt; Téléchargez Messenger, c'est gratuit ! <br>&gt; &gt; &lt;http://www.windowslive.fr/messenger/&gt;<br>&gt; &gt; <br>&gt; &gt; <br>&gt; &gt; ------------------------------------------------------------------------<br>&gt; &gt; <br>&gt; &gt; _______________________________________________<br>&gt; &gt; mapserver-users mailing list<br>&gt; &gt; mapserver-users@lists.osgeo.org<br>&gt; &gt; http://lists.osgeo.org/mailman/listinfo/mapserver-users<br>&gt; <br>&gt; -- <br>&gt; Julien-Samuel Lacroix<br>&gt; Mapgears<br>&gt; http://www.mapgears.com/<br><br /><hr />Centralisez tous vos comptes mails dans Hotmail !  <a href='http://www.windowslive.fr/hotmail/' target='_new'>Créez un compte Hotmail, c'est gratuit !</a></body>
</html>