<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40">

<head>
<meta http-equiv=Content-Type content="text/html; charset=utf-8">
<meta name=Generator content="Microsoft Word 12 (filtered medium)">
<style>
<!--
 /* Font Definitions */
 @font-face
        {font-family:Wingdings;
        panose-1:5 0 0 0 0 0 0 0 0 0;}
@font-face
        {font-family:"Cambria Math";
        panose-1:2 4 5 3 5 4 6 3 2 4;}
@font-face
        {font-family:Calibri;
        panose-1:2 15 5 2 2 2 4 3 2 4;}
@font-face
        {font-family:Tahoma;
        panose-1:2 11 6 4 3 5 4 4 2 4;}
 /* Style Definitions */
 p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0in;
        margin-bottom:.0001pt;
        font-size:12.0pt;
        font-family:"Times New Roman","serif";}
a:link, span.MsoHyperlink
        {mso-style-priority:99;
        color:blue;
        text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
        {mso-style-priority:99;
        color:purple;
        text-decoration:underline;}
pre
        {mso-style-priority:99;
        mso-style-link:"HTML Preformatted Char";
        margin:0in;
        margin-bottom:.0001pt;
        font-size:10.0pt;
        font-family:"Courier New";}
p.MsoListParagraph, li.MsoListParagraph, div.MsoListParagraph
        {mso-style-priority:34;
        margin-top:0in;
        margin-right:0in;
        margin-bottom:0in;
        margin-left:.5in;
        margin-bottom:.0001pt;
        font-size:12.0pt;
        font-family:"Times New Roman","serif";}
span.EmailStyle17
        {mso-style-type:personal-reply;
        font-family:"Calibri","sans-serif";
        color:#1F497D;}
span.HTMLPreformattedChar
        {mso-style-name:"HTML Preformatted Char";
        mso-style-priority:99;
        mso-style-link:"HTML Preformatted";
        font-family:"Courier New";}
span.htmltxt1
        {mso-style-name:html_txt1;
        color:black;}
span.htmltag1
        {mso-style-name:html_tag1;
        color:blue;}
span.htmlelm1
        {mso-style-name:html_elm1;
        color:maroon;}
span.htmlatr1
        {mso-style-name:html_atr1;
        color:red;}
span.htmlval1
        {mso-style-name:html_val1;
        color:blue;}
.MsoChpDefault
        {mso-style-type:export-only;}
@page Section1
        {size:8.5in 11.0in;
        margin:1.0in 1.0in 1.0in 1.0in;}
div.Section1
        {page:Section1;}
 /* List Definitions */
 @list l0
        {mso-list-id:908228680;
        mso-list-type:hybrid;
        mso-list-template-ids:-160151830 761719378 67698691 67698693 67698689 67698691 67698693 67698689 67698691 67698693;}
@list l0:level1
        {mso-level-start-at:0;
        mso-level-number-format:bullet;
        mso-level-text:-;
        mso-level-tab-stop:none;
        mso-level-number-position:left;
        text-indent:-.25in;
        font-family:"Calibri","sans-serif";
        mso-fareast-font-family:Calibri;}
ol
        {margin-bottom:0in;}
ul
        {margin-bottom:0in;}
-->
</style>
<!--[if gte mso 9]><xml>
 <o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
 <o:shapelayout v:ext="edit">
  <o:idmap v:ext="edit" data="1" />
 </o:shapelayout></xml><![endif]-->
</head>

<body lang=EN-US link=blue vlink=purple>

<div class=Section1>

<p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";
color:#1F497D'>If I understand what you want correctly, this is shown in the
examples.  <o:p></o:p></span></p>

<p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";
color:#1F497D'><o:p>&nbsp;</o:p></span></p>

<p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";
color:#1F497D'>I used it in my project (demo here):  <a
href="http://marjie.info/map/">http://marjie.info/map/</a><o:p></o:p></span></p>

<p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";
color:#1F497D'><o:p>&nbsp;</o:p></span></p>

<p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";
color:#1F497D'>In the javascript, after initialiazing your map:<o:p></o:p></span></p>

<p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";
color:#1F497D'><o:p>&nbsp;</o:p></span></p>

<p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";
color:#1F497D'>map.addControl(new OpenLayers.Control.LayerSwitcher(<o:p></o:p></span></p>

<p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";
color:#1F497D'>                { 'div': OpenLayers.Util.getElement('right')
}));<o:p></o:p></span></p>

<p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";
color:#1F497D'><o:p>&nbsp;</o:p></span></p>

<p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";
color:#1F497D'>In the html:<o:p></o:p></span></p>

<p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";
color:#1F497D'><o:p>&nbsp;</o:p></span></p>

<p class=MsoNormal style='background:white'><span style='font-size:10.0pt;
font-family:"Courier New";color:blue'>&lt;</span><span style='font-size:10.0pt;
font-family:"Courier New";color:maroon'>div</span><span style='font-size:10.0pt;
font-family:"Courier New";color:blue'> </span><span style='font-size:10.0pt;
font-family:"Courier New";color:red'>id</span><span style='font-size:10.0pt;
font-family:"Courier New";color:blue'>=&quot;right&quot; </span><span
style='font-size:10.0pt;font-family:"Courier New";color:red'>class</span><span
style='font-size:10.0pt;font-family:"Courier New";color:blue'>=&quot;olControlLayerSwitcher&quot;&gt;&lt;/</span><span
style='font-size:10.0pt;font-family:"Courier New";color:maroon'>div</span><span
style='font-size:10.0pt;font-family:"Courier New";color:blue'>&gt;<o:p></o:p></span></p>

<p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";
color:#1F497D'><o:p>&nbsp;</o:p></span></p>

<p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";
color:#1F497D'>You will probably want to override the ControlLayerSwitcher
style in your CSS as well.<o:p></o:p></span></p>

<p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";
color:#1F497D'><o:p>&nbsp;</o:p></span></p>

<p class=MsoListParagraph style='text-indent:-.25in;mso-list:l0 level1 lfo1'><![if !supportLists]><span
style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'><span
style='mso-list:Ignore'>-<span style='font:7.0pt "Times New Roman"'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
</span></span></span><![endif]><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";
color:#1F497D'>Marjie<o:p></o:p></span></p>

<p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";
color:#1F497D'><o:p>&nbsp;</o:p></span></p>

<div style='border:none;border-top:solid #B5C4DF 1.0pt;padding:3.0pt 0in 0in 0in'>

<p class=MsoNormal><b><span style='font-size:10.0pt;font-family:"Tahoma","sans-serif"'>From:</span></b><span
style='font-size:10.0pt;font-family:"Tahoma","sans-serif"'>
users-bounces@openlayers.org [mailto:users-bounces@openlayers.org] <b>On Behalf
Of </b>Tonton<br>
<b>Sent:</b> Tuesday, May 25, 2010 6:26 AM<br>
<b>To:</b> users@openlayers.org<br>
<b>Subject:</b> [OpenLayers-Users] [openlayers users]<o:p></o:p></span></p>

</div>

<p class=MsoNormal><o:p>&nbsp;</o:p></p>

<p class=MsoNormal>hello <br>
<br>
i would like to have a layers switcher in external of the map box.<br>
<br>
is it possible to use OL for or is it necessary to use a other JS library with<br>
<br>
<br>
<br>
i thing about something like that <br>
<br>
&lt;/script&gt;<br>
&nbsp;function valider()<br>
{&nbsp; var valeur = document.choisir.nomdeCouche;<br>
<br>
&nbsp;&nbsp;&nbsp; for (var i=1;i &lt; valeur.length; i++)<br>
&nbsp;&nbsp;&nbsp; {&nbsp;&nbsp;&nbsp; if ( valeur[i].checked )<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; {&nbsp;&nbsp; map.layerContainerDiv.children([valeur[i].value].<b><span
style='color:#CC0000'>setvisible=true</span></b>);<br>
&nbsp;&nbsp;&nbsp; }&nbsp;&nbsp; else
{map.layerContainerDiv.children([valeur[i].value])<b><span style='color:#CC0000'>.setvisible=false</span></b>;}<br>
&nbsp; }<br>
}&lt;/script&gt;<br>
<br>
&nbsp;&lt;FORM form id='choisir' name='choisir' method=get
action=&quot;javascript:void(0);&quot; onSubmit=&quot;valider(); return false;&quot;&gt;<br>
&lt;input id=&quot;wms1&quot; name=&quot;nomdeCouche&quot;
type=&quot;checkbox&quot;&nbsp; value=&quot;wms1&quot;&gt;&lt;br&gt;<br>
&lt;input id=&quot;wms2&quot; name=&quot;nomdeCouche&quot;
type=&quot;checkbox&quot; value=&quot;wms2&quot;&gt;&lt;br&gt;<br>
&lt;input id=&quot;wms3&quot; name=&quot;nomdeCouche&quot;
type=&quot;checkbox&quot; value=&quot;wms3&quot;&gt;&lt;br&gt;<br>
&lt;input id=&quot;wms4&quot; name=&quot;nomdeCouche&quot; type=&quot;checkbox&quot;
value=&quot;wms4&quot;&gt;&lt;br&gt;<br>
&lt;input type=&quot;submit&quot; value=&quot;ajouter&quot; &gt;<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
&lt;/FORM&gt;<br>
<br>
thanks for your comments<o:p></o:p></p>

</div>

</body>

</html>