[Mapserver-users] question on linking

Peter.Bruton at CCRS.NRCan.gc.ca Peter.Bruton at CCRS.NRCan.gc.ca
Wed Mar 19 14:21:21 EST 2003


This message is in MIME format. Since your mail reader does not understand
this format, some or all of this message may not be legible.

------_=_NextPart_001_01C2EE4C.B9191870
Content-Type: text/plain;
	charset="iso-8859-1"

Hello;
 
Assuming your counties layer is an ArcView polygon shapefile, you could
imbed URLs to other pages in an attribute of the shapefile's dbf.  Your
mapping user interface would require an query function.  A user would
activate the query function and then click on one of the counties.  The
county Layer would have a TEMPLATE property.   A popup browser window would
appear that contains the results of the query.  One of the returned
attributes would be a URL to a particular counties page.  The value of the
attribute in the shapefile could take the following format:
 
<a href=" http://www.place.com/county/county_info.html
<http://www.place.com/county/county_info.html> ">County A</a>  
 
Have a good day.

-----Original Message-----
From: Dan Arnold [mailto:Dan.Arnold at noaa.gov]
Sent: Wednesday, March 19, 2003 2:03 PM
To: mapserver-users at lists.gis.umn.edu
Subject: [Mapserver-users] question on linking


Hello all-
 
Very new to MapServer (like 3 days) and have been searching the doc's, faq's
and have had no luck finding what I'm looking for. 
 
I'm trying to create a map of a state that displays county outlines on the
map and for each county I'd like to be able to link to a different page.
 
I don't want to pan, or zoom in/out.. just a simple link to another page.
For example if you click on "county_01" on my map it would send you to
"county_01.php" if you clicked on "county_02" you'd go to "county_02.php"
etc...
 
I can create the map with the county lines, but I don't know how to "link"
them to a separate page.
 
Can this be done? And if it can, anyone have any sample code I could look
at?
 
Any help would be appreciated!

--
Dan Arnold
Webmaster
National Weather Service
Central Region Headquarters
dan.arnold at noaa.gov <mailto:dan.arnold at noaa.gov> 
816.891.7734 x486

 


------_=_NextPart_001_01C2EE4C.B9191870
Content-Type: text/html;
	charset="iso-8859-1"

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=iso-8859-1">
<TITLE>Message</TITLE>

<META content="MSHTML 6.00.2800.1106" name=GENERATOR></HEAD>
<BODY>
<DIV><FONT face=Arial color=#0000ff size=2><SPAN 
class=880160319-19032003>Hello;</SPAN></FONT></DIV>
<DIV><FONT face=Arial color=#0000ff size=2><SPAN 
class=880160319-19032003></SPAN></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial color=#0000ff size=2><SPAN 
class=880160319-19032003>Assuming your counties layer is an ArcView polygon 
shapefile, you could imbed URLs to other pages in an attribute&nbsp;of the 
shapefile's&nbsp;dbf.&nbsp;&nbsp;Your mapping&nbsp;user interface 
would&nbsp;require an&nbsp;query&nbsp;function.&nbsp; A user would activate 
the&nbsp;query function and then click on&nbsp;one of the 
counties.&nbsp;&nbsp;The county Layer would have a TEMPLATE 
property.&nbsp;&nbsp;&nbsp;A popup&nbsp;browser window would appear&nbsp;that 
contains the results&nbsp;of the query.&nbsp; One of the returned attributes 
would be a URL to a particular counties page.&nbsp; The&nbsp;value of the 
attribute in the shapefile could take the following format:</SPAN></FONT></DIV>
<DIV><FONT face=Arial color=#0000ff size=2><SPAN 
class=880160319-19032003></SPAN></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial color=#0000ff size=2><SPAN class=880160319-19032003>&lt;a 
href="<A 
href="http://www.place.com/county/county_info.html">http://www.place.com/county/county_info.html</A>"&gt;County 
A&lt;/a&gt;&nbsp;&nbsp;</SPAN></FONT></DIV>
<DIV><FONT face=Arial color=#0000ff size=2><SPAN 
class=880160319-19032003></SPAN></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial color=#0000ff size=2><SPAN class=880160319-19032003>Have a 
good day.</SPAN></FONT></DIV>
<BLOCKQUOTE dir=ltr style="MARGIN-RIGHT: 0px">
  <DIV class=OutlookMessageHeader dir=ltr align=left><FONT face=Tahoma 
  size=2>-----Original Message-----<BR><B>From:</B> Dan Arnold 
  [mailto:Dan.Arnold at noaa.gov]<BR><B>Sent:</B> Wednesday, March 19, 2003 2:03 
  PM<BR><B>To:</B> mapserver-users at lists.gis.umn.edu<BR><B>Subject:</B> 
  [Mapserver-users] question on linking<BR><BR></FONT></DIV>
  <DIV><FONT face=Arial size=2><SPAN class=765352818-19032003>Hello 
  all-</SPAN></FONT></DIV>
  <DIV><FONT face=Arial size=2><SPAN 
  class=765352818-19032003></SPAN></FONT>&nbsp;</DIV>
  <DIV><FONT face=Arial size=2><SPAN class=765352818-19032003>Very new to 
  MapServer (like 3 days) and have been searching the doc's, faq's and have had 
  no luck finding what I'm looking for. </SPAN></FONT></DIV>
  <DIV><FONT face=Arial size=2><SPAN 
  class=765352818-19032003></SPAN></FONT>&nbsp;</DIV>
  <DIV><FONT face=Arial size=2><SPAN class=765352818-19032003>I'm trying to 
  create a map of a state that displays county outlines on the map and for each 
  county I'd like to be able to link to a 
  different&nbsp;page.</SPAN></FONT></DIV>
  <DIV><FONT face=Arial size=2><SPAN 
  class=765352818-19032003></SPAN></FONT>&nbsp;</DIV>
  <DIV><FONT face=Arial size=2><SPAN class=765352818-19032003>I don't want to 
  pan, or zoom in/out.. just a simple link to another page. For example if you 
  click on "county_01" on my map it would send you to "county_01.php" if you 
  clicked on "county_02" you'd go to "county_02.php" etc...</SPAN></FONT></DIV>
  <DIV><FONT face=Arial size=2><SPAN 
  class=765352818-19032003></SPAN></FONT>&nbsp;</DIV>
  <DIV><FONT face=Arial size=2><SPAN class=765352818-19032003>I&nbsp;can create 
  the map with the county lines, but I don't know how to "link" them to a 
  separate page.</SPAN></FONT></DIV>
  <DIV><FONT face=Arial size=2><SPAN 
  class=765352818-19032003></SPAN></FONT>&nbsp;</DIV>
  <DIV><FONT face=Arial size=2><SPAN class=765352818-19032003><SPAN 
  class=765352818-19032003>Can this be done? And if it can, anyone have any 
  sample code I could look at?</SPAN></SPAN></FONT></DIV>
  <DIV><FONT face=Arial size=2><SPAN class=765352818-19032003><SPAN 
  class=765352818-19032003></SPAN></SPAN></FONT>&nbsp;</DIV>
  <DIV><FONT face=Arial size=2><SPAN class=765352818-19032003><SPAN 
  class=765352818-19032003>Any help would be 
  appreciated!</SPAN></SPAN></FONT></DIV>
  <P align=left><FONT face=Arial size=2>--<BR>Dan 
  Arnold<BR>Webmaster<BR>National Weather Service<BR>Central Region 
  Headquarters<BR><A 
  href="mailto:dan.arnold at noaa.gov">dan.arnold at noaa.gov</A><BR>816.891.7734 
  x486</FONT></P>
  <DIV>&nbsp;</DIV></BLOCKQUOTE></BODY></HTML>

------_=_NextPart_001_01C2EE4C.B9191870--



More information about the mapserver-users mailing list