possible error in location_views_handler_arg_province()

stella - February 14, 2007 - 12:16
Project:Location Views
Component:Code
Category:bug report
Priority:normal
Assigned:Unassigned
Status:active
Description

Hi,

I think there might be a possible bug in location_views_handler_arg_province() when $op is "title". The function currently has:

    case 'title':
      return empty($query) ? LOCATION_VIEWS_UNKNOWN : $provinces[$country .'-'. $query];

As $country is not set at this point, I think there should be a way of providing the $country value or the code should actually be:

    case 'title':
      return empty($query) ? LOCATION_VIEWS_UNKNOWN : $provinces[$query];

If this isn't an error, can you tell me with to call this function with so I get the human readable form of the province from an input of for example "ie-WF"?

Cheers,
Stella

 
 

Drupal is a registered trademark of Dries Buytaert.