Skip Navigation

[Resolved] Single field block does not update modified taxonomy slug

This support ticket is created 3 years, 1 month ago. There's a good chance that you are reading advice that it now obsolete.

This is the technical support forum for Toolset - a suite of plugins for developing WordPress sites without writing PHP.

Everyone can read this forum, but only Toolset clients can post in it. Toolset support works 6 days per week, 19 hours per day.

Sun Mon Tue Wed Thu Fri Sat
- 9:00 – 12:00 9:00 – 12:00 9:00 – 12:00 9:00 – 12:00 9:00 – 12:00 -
- 13:00 – 18:00 13:00 – 18:00 13:00 – 18:00 14:00 – 18:00 13:00 – 18:00 -

Supporter timezone: America/Jamaica (GMT-05:00)

This topic contains 4 replies, has 3 voices.

Last updated by Arno 3 years, 1 month ago.

Assisted by: Shane.

Author
Posts
#2268495

I am trying to: change the slug of a hierarchical taxonomy. The taxonomy was already in use in a single field block on a template, to pull the taxonomy name and show it as a link to the archive. Once I changed the slug, the single field block did not show anything anymore. Clearing the page cache did not help. All plugins are the latest version.

I added another identical single field block after this happened, and it works fine. The one that was there before I changed the slug is still broken. I'd expect the field to update if the taxonomy it pulls data from is changed.

Link to a page where the issue can be seen: hidden link

I expected to see: two identical taxonomy links under "Ticket type" (the old and new one)

Instead, I got: one taxonomy link under "Ticket type" (the new one)

Is this a bug or did I make a mistake? Thanks in advance!

#2268519

Nigel
Supporter

Languages: English (English ) Spanish (Español )

Timezone: Europe/London (GMT+00:00)

The dynamic source of the single field block knows which taxonomy term to output based upon the taxonomy slug.

If you change the settings for the taxonomy to use a different slug then the original single field block will then be referring to something that no longer exists, and hence is broken.

You can simply delete the broken block.

#2268553

Hi Nigel,

Thank you for the quick response. For my understanding: so the slug is the unique ID in WordPress? Changing that requires a site wide search for affected fields to replace?

Or is it a choice made by Toolset to be dependent on the slug, and could this handled differently?

Thanks,
Arno

#2268753

Shane
Supporter

Languages: English (English )

Timezone: America/Jamaica (GMT-05:00)

Hi Arno,

For my understanding: so the slug is the unique ID in WordPress?

Yes the slug is unique however it is not to be confused with the ID. Both ID and Slugs are unique identifier for wordpress.

Changing that requires a site wide search for affected fields to replace?

In most cases the change should be reflected given that the data would be pulled directly from the database. However there are cases where you will need to re-add the block in order for the correct information to be reflected after a change.

As Nigel mentioned If you change the settings for the taxonomy to use a different slug then the original single field block will then be referring to something that no longer exists, and hence is broken.

The recommendation here is to remove and re-add the affected block.

Thanks,
Shane

#2269035

My issue is resolved now. Thank you!