From: shane <sh...@lo...> - 2006-08-29 15:06:40
|
On Aug 29, 2006, at 10:16 AM, Larson, Timothy E. wrote: > shane wrote: >> On Aug 25, 2006, at 4:59 PM, Larson, Timothy E. wrote: >>> I'd've been happy with a even a list of regions/countries to choose >>> from when submitting stories. How hard is it to reliably map any >>> given coordinate pair to a city/country/state/area? I can certainly >>> see the utility in finding local postings (i.e. "within 200 km of >>> <coord>") but more likely (for my needs) I'd want to focus on >>> "Canada" or "Manhattan" or "Middle East". It certainly would be >>> easier (for non-geography buffs) to submit something like this (i.e. >>> picking from a list, clicking a map region) with stories rather than >>> coordinate pairs. >> >> Where would one obtain such data? > > It would have to be defined somewhere on the site, but that would be > done by the admins during setup, and only once. If this GeoRSS > thing is > that big already, I imagine someone somewhere has already done some of > the work: defining the boundaries of countries, states, cities, > landmasses, etc. You'd just have to pick the ones that work for you, > and fill in the gaps. We may have a stop gap here - http://www.lottadot.com/projman.pl?op=view&id=15 I had started that zipcode plugin, well, a very long time ago. As far as I recall, it was functional last time I messed with it. If you can, take a look at it, specifically the schema and the data it contains. From a quick glance, it looks like it has lat/long information by zip/city/state. However, defining boundaries w/ landmasses et all, er yuk. > >>> So this only applies to RSS, and you won't notice anything when >>> visiting the site otherwise? >> >> No. If a story has geo-data associated with it, it'll show a map. >> Example: >> >> http://industry.slashgeo.org/article.pl?sid=06/07/27/1337233 >> >> It will also add tags into the html such as >> >> <meta name="geo.position" content="51.5;-0.1"> >> >> For more info on the tags: http://www.lottadot.com/projman.pl? >> op=viewissue&id=5 > > Very very very cool. Especially if the map view is customizable. The maps are drawn via a template. The template expects certain things passed to it (map api key, lat, long, points) But other then that, it will be very, very highly mod'able. > >>> If the story has location info, I'd want to see it in the story >>> somewhere. >> >> Where? And what? That's been the big question. > > That depends on the nature of the site. A "hard news" site would > prefix > "Dateline: New York" to the story submission, perhaps. > >>> I think it would be a huge value-add, and very useful, especially > were >>> it given the ability to use "general" location as well as "specific" >>> location. >> >> In what way? To search the stories? To filter them on an index view >> (as you could filter by author, or by topic?) > > Precisely! That was my original vision for how it would work in that > low-pri request. It would be a fourth piece of data along with topic, > section, and author. One would be able to filter the homepage on > location just as with those three. > > In fact, 699047 describes an enhancement to home page customization > that > would make use of this field. Since that request, a different > enhancement has been done, but the idea of using locale is still cool. > On slashdot, for example, sure it's interesting that some big business > 10 timezones away is switching operations to Linux, but I'm also > interested in the much less earthshaking news of an Open Software > Festival sponsored by a high school club in the next county. By > adding > support for location, big sites can still cover local news without > "spamming" the non-locals. How would this be any different from having a topic-nexus defined that would hold all stories associated with a certain area? Then all a user has to do is hit the URL for skin to obtain that content. I bring that solution up, because that doesn't entail modifying any source code, nor schema. So far, to get the functionality that's mentioned on the project homepage ( http://lottadot.com/projects/ slashmaps ) I've not had to modify all that much source code to get these things to work. Mostly we're using topic_nexus_extras to store the information, and modified templates to show it. (I did have to complete the skins editor, and the skins_params, but that's another topic). Inorder for one to be able to essentially search by story.location (let's assume that's what it's called) efficiently, at first thought I would think we'd have to modify the stories table schema, add that column, and then modify all the story code (getStoriesEssentials,etc) in Slash.pm as well as retool a bit of Slash::Search. Then add a bit to the edituser page that would let them set the 'region/place' limiting options (just like they can exclude authors, topics). At first glance, that seems like quite a bit of work. Maybe there'd be a better way to do it. Any thoughts? I'm all ears. Another question I would have, is if you're wanting to associate a story with a location, how do you let a user exclude? by proximity to that location? how do you define proximity? lat/long? within XX miles? but that's US, so you'd want to investigate using an alternative metric. Shane -- My slashcode stuff: http://slash.lottadot.com/ Slashcode faq: http://slash.lottadot.com/slash-faq How to ask a question: http://www.catb.org/~esr/faqs/smart- questions.html#before |