AFAIK, A web crawler only follows links. As such, it doesn't care whether something is a directory, an actual file, or something that _looks_ like a file. I believe that most crawlers will ignore things after a ? and so normal cgi, php, etc. links don't get indexed.
<br><br>I have never used mod_rewrite with maps, but I use it for just about all the content on <a href="http://www.macnoise.com">http://www.macnoise.com</a>. As you can see (<a href="http://www.google.com/search?q=+site:www.macnoise.com+macnoise">
http://www.google.com/search?q=+site:www.macnoise.com+macnoise</a>) all the links which are actually generated by php get crawled. For example: <a href="http://www.macnoise.com/maps">www.macnoise.com/maps</a> actually pulls up
<a href="http://www.macnoise.com/index2.php?page=maps">www.macnoise.com/index2.php?page=maps</a>.<br><br>Hope this helps. I'd be curious to hear if you use this approach and if it works for you. I think that it's really cool how you just use different 'directories' as spatial bookmarks.
<br><br>David<br><br><div><span class="gmail_quote">On 7/12/06, <b class="gmail_sendername">Steve Walker</b> <<a href="mailto:walker@mfgis.com">walker@mfgis.com</a>> wrote:</span><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
David,<br><br>Thank you for the response.<br><br>mod_rewrite does sound very powerful and I will look into it.<br><br>Having not yet done so, will you forgive me the following follow-up<br>questions-<br><br>As I understand you, the web-visible URL need not exist as a pysical page,
<br>it could just as easily be a value ('California') associated with a<br>record in a database grabbed via a cgi script as massaged by mod_rewrite.<br><br>However, I may wish for the page to actually physically exist (i.e
. so web<br>crawlers can find it).<br><br>In which case, how does one proceed? Could empty system directories<br>and/or files serve the purpose:<br><br>/var/www/htdocs/Washington<br>/var/www/htdocs/California<br>/var/www/htdocs/California/Los_Angeles
<br>/var/www/htdocs/California/Los_Angeles/Hollywood.html<br>/var/www/htdocs/California/Los_Angeles/East_LA.html<br><br>Such that a web crawler would find a physical page for Los_Angeles but<br>mod_rewrite would re-write the URL into a SQL query for use by a cgi-bin
<br>script to have my database provide the content?<br><br>If that's what you're telling me then Sign Me Up!<br><br><br>Thanks again,<br><br>-steve<br><br><br><br><br>> Steve --<br>><br>> You really should take a look at mod_rewrite, I think that it would really
<br>> be quite easy to do what you are trying to accomplish.<br>><br>> The basic idea is that you would setup a rule in apache that would take<br>> any<br>> url of the form <a href="http://www.usmapserver.com/california">
http://www.usmapserver.com/california</a> and you would<br>> internally (the end user will never see what you are doing) change that<br>> url<br>> to <a href="http://www.usmapserver.com/index.html?state=california">
http://www.usmapserver.com/index.html?state=california</a>. Then you would<br>> just need to have a lookup in index.html that would find the bbox for ca<br>> and<br>> would zoom in there.<br>><br>> It's actually pretty darn slick when you get it running.
<br>><br>> David<br>><br>> On 7/12/06, Steve Walker <<a href="mailto:walker@mfgis.com">walker@mfgis.com</a>> wrote:<br>>><br>>><br>>> I have partially solved my own question posted below.
<br>>><br>>> I have discovered the following:<br>>><br>>> To view multiple pages such as<br>>> <a href="http://www.blahblah.com/location1">http://www.blahblah.com/location1</a> and<br>>>
<a href="http://www.blahblah.com/location2">http://www.blahblah.com/location2</a><br>>><br>>> from the same ka-map back-end, do the following:<br>>><br>>> Modify the init.php, changing file 'includes' as necessary to point to
<br>>> the<br>>> correct locations on the file system (ie tile.php, config.php) as you<br>>> will<br>>> copy the init.php file to multiple locations on the file system and the<br>>> relative pointers to these files may/will break.
<br>>><br>>> Also in init.php, insert the line<br>>> include_once('./variables.php');<br>>> before the include_once( 'config.php) entry. This pulls in the<br>>> variables<br>>> (extent, map name, title) as noted in my original posting.
<br>>><br>>> modify the *.js files again to replace path names as necessary, for the<br>>> same reason as above (ie from 'images/blahblah.jpg' to<br>>> '/ka-map/images/blahblah.jpg'<br>>><br>
>> copy both the init.php files to the corresponding location(s) on the<br>>> file<br>>> system.<br>>><br>>> re-write the index.html files (using scripts & templates) to reflect the<br>>> page-specific values from
variables.php such as name, title, etc.<br>>><br>>> /var/www/htdocs/location1/init.php<br>>> /var/www/htdocs/location1/index.html<br>>> /var/www/htdocs/location1/variables.php<br>>><br>>> /var/www/htdocs/location2/init.php
<br>>> /var/www/htdocs/location2/index.html<br>>> /var/www/htdocs/location2/variables.php<br>>><br>>> This solution works as you can see for example from<br>>><br>>> <a href="http://www.usmapserver.com/Washington">
www.usmapserver.com/Washington</a><br>>> <a href="http://www.usmapserver.com/California">www.usmapserver.com/California</a><br>>> <a href="http://www.usmapserver.com/California/Los_Angeles">www.usmapserver.com/California/Los_Angeles
</a><br>>><br>>> However, drawbacks include:<br>>><br>>> 1. need to make a copy of init.php for each desired web page rather<br>>> than<br>>> pointing to a single master.<br>>> 2. need to (progromatically) re-write each
index.html (ie to generate<br>>> title, name, links) from scratch rather than including these values at<br>>> run-time.<br>>><br>>> I am still scratching at the surface of understanding and will report
<br>>> anything else I learn.<br>>><br>>> -steve walker<br>>><br>>> > Hello,<br>>> ><br>>> > I am hoping to be able to achieve the following:<br>>> ><br>>> > Have
<br>>> > <a href="http://www.usmapserver.com/location1">http://www.usmapserver.com/location1</a><br>>> > <a href="http://www.usmapserver.com/location2">http://www.usmapserver.com/location2</a><br>>> > (and n additional URLS)
<br>>> ><br>>> > each launch the same ka-map application (same map, data, etc)<br>>> > but so that each grabs its extent and title (among other things) from<br>>> > the URL's index.php
file as here:<br>>> ><br>>> > /var/www/htdocs/location1/index.php:<br>>> > $title = 'Map of Green City';<br>>> > $extent = '-120,40,-115,45';<br>>> > $include ("/var/www/htdocs/kamap_index.html");
<br>>> ><br>>> > /var/www/htdocs/location2/index.php:<br>>> > $title = 'Map of Red Town';<br>>> > $extent = '-90,30,-70,40';<br>>> > $include ("/var/www/htdocs/kamap_index.html");
<br>>> ><br>>> > where of course location1/index.php corresponds with<br>>> > http:/www.usmapserver.com/location1 etc.<br>>> > and where kamap_index.html is essentially the ka-map distribution
<br>>> html.<br>>> ><br>>> > My idea is to replace (in init.php) the extents read from the map file<br>>> > $szExtents = $oMap->extent->minx.",".$oMap->extent->miny.",".
<br>>> > $oMap->extent->maxx.",".$oMap->extent->maxy;<br>>> ><br>>> > with<br>>> ><br>>> > $szExtents = $extent;<br>>> ><br>>> > where $extent is the $extent variable in
index.php<br>>> ><br>>> > (CF The analogous setup using the chameleon environment at<br>>> <a href="http://usmaperver.com">usmaperver.com</a><br>>> > - a web page for each state, county, and city in the nation.)
<br>>> ><br>>> ><br>>> > The problem, as I understand it, is that these variables don't get<br>>> passed<br>>> > through. And here is where my skills break down - specifically on the
<br>>> the<br>>> > javascript side.<br>>> ><br>>> > I can *fake it* but only for one page: In init.php, near the line<br>>> > include_once( '/var/www/htdocs/include/config.php' );
<br>>> ><br>>> > I can add<br>>> > include_once( '/var/www/htdocs/location1/variables.php' );<br>>> ><br>>> > But this will only work if hard-wired to the 'location1/variables.php'
<br>>> > and since I don't know how to move these variables through, I can't<br>>> write<br>>> ><br>>> > $variable_path = '/var/www/htdocs/' . $url_base . '/variables.php';<br>>> > include_once( $variable_path );
<br>>> ><br>>> > where $url_base would be one of location1,location2,...,locationN<br>>> ><br>>> ><br>>> > Does this make sense? Clearly I wouldn't even need to bother with<br>
>> this<br>>> > kluggy 'include_once' in init.php if those variables originally<br>>> defined<br>>> in<br>>> > index.php were passed through.<br>>> ><br>>> > I think I am missing something simple (php globals? javascript
<br>>> anything?)<br>>> ><br>>> ><br>>> > Thanks for any insights.<br>>> ><br>>> ><br>>> ><br>>> ><br>>> > --<br>>> > Steve Walker<br>
>> > Middle Fork Geographic Information Services<br>>> > <a href="mailto:walker@mfgis.com">walker@mfgis.com</a><br>>> > 360-671-2505<br>>> ><br>>> > _______________________________________________
<br>>> > ka-Map-users mailing list<br>>> > <a href="mailto:ka-Map-users@lists.maptools.org">ka-Map-users@lists.maptools.org</a><br>>> > <a href="http://lists.maptools.org/mailman/listinfo/ka-map-users">
http://lists.maptools.org/mailman/listinfo/ka-map-users</a><br>>> ><br>>><br>>><br>>> --<br>>> Steve Walker<br>>> Middle Fork Geographic Information Services<br>>> <a href="mailto:walker@mfgis.com">
walker@mfgis.com</a><br>>> 360-671-2505<br>>><br>>> _______________________________________________<br>>> ka-Map-users mailing list<br>>> <a href="mailto:ka-Map-users@lists.maptools.org">ka-Map-users@lists.maptools.org
</a><br>>> <a href="http://lists.maptools.org/mailman/listinfo/ka-map-users">http://lists.maptools.org/mailman/listinfo/ka-map-users</a><br>>><br>><br>><br>><br>> --<br>> ************************************
<br>> David William Bitner<br>> <a href="mailto:bitner@gyttja.org">bitner@gyttja.org</a><br>><br><br><br>--<br>Steve Walker<br>Middle Fork Geographic Information Services<br><a href="mailto:walker@mfgis.com">walker@mfgis.com
</a><br>360-671-2505<br><br></blockquote></div><br><br clear="all"><br>-- <br>************************************<br>David William Bitner<br><a href="mailto:bitner@gyttja.org">bitner@gyttja.org</a>