[support] str_replace in views argument

Scott scott at bscottholmes.com
Wed Jan 6 17:10:29 UTC 2010


My second argument for a gmap style view is a city name, provided by
url.  It works fine for single word city names like 'Reseda' but not for
multiple word names like 'Canoga Park'.  The url supplies the name as
'Canoga_Park', with an underscore.  I need to remove the underscore for
the gmap lookup.  I've set the default argument for Location:City to

return str_replace('_', ' ', $arg[2]);

No joy.  I suspect this has something to do with the limitation that the
argument return only a single value but I don't know enough about the
underlying system to tell and I don't know how to debug a view.



More information about the support mailing list