I was having an issue where I wanted to use the full address as a single field in my view, but I couldn't get rid of the country name.

The issue is that currently the field options allow you to exclude the country, but that doesn't also exclude the country name. I have been able to hack a fix, by changing the following line in location_handler_field_location_address.inc:

      '#options' => location_field_names(),

to:

      '#options' => location_field_names(TRUE),

It does also have the side effect of giving you options to exclude options that won't appear even if unchecked, however (such as map links). Truth be told, however, I'd actually like to have those available in my views

If my change would be of use to anyone else, I'd be happy to roll a patch.

Comments

mandclu’s picture

Version: 6.x-3.0-rc2 » 6.x-3.0
summit’s picture

Version: 6.x-3.0 » 6.x-3.x-dev

Hi Martin,

Yes please unroll a patch. Will your change make also posisble to unselect the country name?

greetings,
Martijn

yesct’s picture

Summit, I think you mean roll (or maybe create) a patch. unroll, would be ... hmm I dont know. Some times people will say re-roll to do a patch again, like if a patch is against 1.3 and 1.5 is available, someone might request the patch get re-rolled against 1.5. :)

But I think we knew what you meant! :)

Anyway, surge_martin, could you also explain a little bit more about your problem and the side effects? Maybe some before and after screen shots would help a lot.

yesct’s picture

Component: Code » Location_views
yesct’s picture

Status: Active » Postponed (maintainer needs more info)

No action on this in a long time. If this is still a problem in the newest official release or new dev release, please post back withing 2 week, and set the status back to active. Thanks.

pelicani’s picture

just to add, this was a problem in the 6.3 code (and perhaps before as well)
but it is now working correctly in 6.3.1
thanks

rooby’s picture

Status: Postponed (maintainer needs more info) » Fixed

Reported as being resolved in latest version.

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.