business-profile icon indicating copy to clipboard operation
business-profile copied to clipboard

Seems to fix issue with the address passed to Google when getting directions.

Open LowellMontgomery opened this issue 7 years ago • 2 comments

Encoding a business with an apostrophe in the name put ' in the search field, so it seems urlencode() is not appropriate here and esc_attr() does not seem to be necessary here, either. After this change, I correctly get directions instead of an error. I think I would get an error even without the apostrophe since I think the esc_attr was removing separations for the address lines, which now correctly appear as commas.

LowellMontgomery avatar Feb 03 '18 21:02 LowellMontgomery

This is what I was getting prior to my "fix": Illustration of the error with get directions

LowellMontgomery avatar Feb 03 '18 21:02 LowellMontgomery

But actually, I think my change only fixes one of the links. I think it's still possible to still get the error by clicking the other link. (There are links by both the map and the address, depending on config). I need to look at this again and fix the second (and maybe properly create an "issue" for this).

LowellMontgomery avatar Feb 07 '18 03:02 LowellMontgomery