Posted by mikl on March 24, 2009 at 1:56pm
| Project: | Location |
| Version: | 6.x-3.x-dev |
| Component: | Data update |
| Category: | task |
| Priority: | normal |
| Assigned: | mikl |
| Status: | closed (fixed) |
Issue Summary
I've expanded location.dk.inc with map links to the Danish map site, findvej.dk.
Patch attached :)
| Attachment | Size |
|---|---|
| dk.location.patch | 3.23 KB |
Comments
#1
Some nits:
* Don't use sprintf. Concatenation is fine. Using url() to do the heavy lifting is best.
* findvej.dk seems to be fine with using just a postcode, there should be a case for that, no?
* I'd prefer lat/lon over the rest of the choices, rather than the other way around. This makes it easier on the geocoder.
* You should use location_has_coordinates() to check whether the location has latitude / longitude set. This catches corner cases like stuff set to "0.0000" and so forth.
* You're checking if the fields are set, but you aren't checking if they are empty or not when determining the link.
* The raw ampersand when you're putting together the lat/lon url is suspect. In HTML this must be changed to the & entity.
* You accidentally joined the cvs id line with the top line of the file. (I automatically fix stuff like this when testing patches, so it's not actually a problem as such.)
#2
Okay, re-roll:
#3
Can someone try this new patch?
#4
I've made a new patch with support for the Danish public transportation guide, Rejseplanen.dk :)
#5
This latest patch isn't applying for me for some reason. I therefore attach my own version which I rolled based upon yours.
#6
Committed to DRUPAL-6--3 and HEAD.
#7
http://drupal.org/cvs?commit=347480
#8
Automatically closed -- issue fixed for 2 weeks with no activity.