What’s the exact code you added to the function.php?
Are you also using a custom template? If so, then also please share that code.
Don’t past all the code here, but create a gist on Github.
Thread Starter
Hjsurk
(@hjsurk)
Hello,
I am not using a custom template. I tried using this function without success:
https://gist.github.com/anonymous/0de041caff67cd719dd5d12d1fda5035
Just seems to add the option in the dropdown without changing anything, not even translating with the rest of the options.
Probably using the wrong function for that, but the main problem is not having any spaces at all in the standard choices.
The code is fine, but I can’t replicate the issue with a default theme.
I do see spaces between the city / state and zip code.
Can you test with a default WP theme, and all other plugins disabled to rule out another script is messing with the output.
You can also use this filter to overwrite the default search template and include the spaces yourself.
Copy the code from the usage section and place it in the functions.php inside your active theme folder. Instead of ” . wpsl_address_format_placeholders() . ” on line 15 you can include <%= city %>, <%= state %>, <%= zip %>.
-
This reply was modified 8 years, 4 months ago by
Tijmen Smit.
Thread Starter
Hjsurk
(@hjsurk)
Hello Tijmen,
Thanks for the suggestions. Disabling WP Super Minify did the trick!