By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
459,466 Members | 1,176 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 459,466 IT Pros & Developers. It's quick & easy.

Help with Mapserver, HTML and JAvascript

P: 2
Hello, I'm a newbie in all this called "web page design" and all of that. I´m a cartographer in a small village called Oliva, in Valencia, Spain. I've made a mini-course about how to publicate cartography in the Web. I know a little about html and UmnMapserver. Mi page is only Intranet, and very basic. But I'm looking the way for doing this: select a street, then a number, and the map zooms where the coordinates in the table signs. I´ve found the "cascading selects" script. It´s half of my problem. I have a table with street names and then for each street a table with the number of the house. In this last table, are booked the coordinates X,Y where the center of the house is situated. ¿How can I do to get this coordinates into the html page an the zooms center in it? ¿have you seen something useful for this, a script in the web or something like that? I've found a very simple page wich do that, but I'm not able to descifrate the code, that page do exactly what I want:
http://svaj.webhouse.dk/gentofte_web...kortopslag.asp
Thanks, Lara
Jun 12 '07 #1
Share this Question
Share on Google+
2 Replies


acoder
Expert Mod 15k+
P: 16,027
Lara, Welcome to TSDN!

Javascript won't be enough. Can you show some code that you've been working with.
Jun 12 '07 #2

P: 2
I haven´t insert the cascading select script yet in the html page. but you can see it in
http://www.fh54.de/js/cascadingselects/
Here yo have my html archive. It's so basic, sorry:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<html>
<head>
</head>

<body bgcolor="#ffffff">
<form name=mapserv action="/cgi-bin/mapserv44" method="post">

<FONT FACE="Arial, Helvetica, sans-serif" SIZE="2">

<table width="100%" border="0" cellpadding="0" cellspacing="0">
<tr>
<!-- Primera columna: el borde-->
<td align="left" width="150" valign="top" bgcolor="#ECF0F3">
</td>
<!-- Segunda columna: el mapa de referencia-->
<td align="center">
<table border="0" cellpadding="3" cellspacing="0" bordercolor="0""">
<tr>
<td colspan="3" cellpadding="0">
<IMG src="/icons/foto.jpg"</td>
</tr>
<tr>
<td width="150" valign="top">
<input type="submit" value="Actualizar">
<br>
<br>
<input type="image" name="ref" src="[ref]" border="0">
<br>
<br>
<input type="radio" name="zoom" value="2" [zoom_2_check]>
<IMG SRC="/icons/zoomin.gif" WIDTH="25" HEIGHT="25">&nbsp;Acercar<br>
<input type="radio" name="zoom" value="1" [zoom_1_check]>
<IMG SRC="/icons/recentre.gif" WIDTH="25" HEIGHT="25">&nbsp;Centrar<br>
<input type="radio" name="zoom" value="-2" [zoom_-2_check]>
<IMG SRC="/icons/zoomout.gif" WIDTH="25" HEIGHT="25">&nbsp;Alejar<br>
</td>
<!-- Tercera columna: el mapa -->
<td width="800" align="center" valign="center">
<input type="image" name="img" src="[img]" border="0"> <br>
<strong>Escala: </strong>[scale]
</td>
<!-- Cuarta columna: controles -->
<td width="200" align="left" valign="top">
<h3>Nucleos Urbanos:</h3>
<select name="mapext">
<option value="">Elige una zona</option>
<option value="751250 4313950 751850 4313200"> Kiko</option>
<option value="750700 4314400 751400 4313400"> Sectores 6 y 19</option>
<option value="750500 4314700 751000 4314150"> Terranova</option>
<option value="751800 4313300 752800 4312300"> Poblado Marítimo</option>
<option value="751550 4313000 752400 4312200"> Canyades</option>
<option value="752200 4312500 753500 4311450"> Aigües Blanques</option>
<option value="754000 4310600 754750 4310050"> Rabdells</option>
<option value="754250 4310500 756550 4308200"> Oliva Nova y San Fernando</option>
<option value="752350 4310050 753600 4309100"> Jovades</option>
<option value="750500 4311250 751700 4310400"> Sectores 3 y 16</option>
<option value="748700 4312900 750850 4310550"> Casco Urbano</option>
<option value="750200 4313000 750850 4310550"> Sector 15</option>
<option value="750180 4312900 751100 4312000"> Sector 2</option>
</select>
<br>
<br>
<input type="submit" value="Ir">
<br>
<br>
<input type="checkbox" name="layer" value="DISTRITOS" [DISTRITOS_check]>
Distritos<br>
</td>
</tr>
</table>
<!-- Quinta columna: el borde-->
<td width="150" valign="top" bgcolor="#ECF0F3">
</td>
</table>

<!-- VARIABLES CGI OCULTAS DE MAPSERVER -->
<input type="hidden" name="map" value="[map]">
<input type="hidden" name="imgext" value="[mapext]">
<input type="hidden" name="imgxy" value="300 250">
</form>

<P align="right"><a href="/index.html">Volver</a></p>
</FONT>
</body>
</html>

What i really want to do it´s in that web page I said:
http://svaj.webhouse.dk/gentofte_web...kortopslag.asp
Jun 13 '07 #3

Post your reply

Sign in to post your reply or Sign up for a free account.