We have several buildings with flats that are available for rent. This is assisted living for elderly.
I use a taxonomy for the buildings since this taxonomy is also used on other parts of the site.
In my content template for 'flat' i placed a button "More info or rent?"
I'm trying to construct a dynamic URL: hidden link type="location" format="name"]&flat=[types field='flat-number'][/types]
The flatnumber is shown in the URL, but no matter what i try, the taxonomy does not show and stays empty.
I can place [wpv-post-taxonomy type="location" format="name"] whereever i want in the content template, it works. Just not when building the URL for a button.
I use the URL parameters in the form on the /request-info page so we know what building and flat people are inquiring about.
Any suggestions?
Many thanks!
The problem is that you're using double quotes inside the shortcode which most likely results in the URL tag being closed early. Try using single quotes like this [wpv-post-taxonomy type='location' format='name']
Please let me know if this resolves the issue for you.
I overlooked the obvious. Double quotes instead of single qoutes 🤦♂️
However, i did generate the shortcodes via the "Toolset Shortcode" link in the upper admin bar. I just tested: when generating a shortcode for a custom field, the shortcode is incapsulated with single qoutes. When i do the same for taxonomies, there are double quotes. I just copy/paste without looking. Maybe this is a bug?