Hierarchy Slug
-
Due to how we have to structure our filtering we have edited woocommerce to allow for hierarchy of attributes. This is working just fine but does result in us having to create sub-attributes for each of our parent attributes which does result in quite a few attributes that share common names. As we want them to display with the correct name we are trying to use slugs to give them a unique way to identify. We can do this manually but it is quite a chore.
Currently when you add an attribute and you leave the slug field blank woo just takes the name and lower capitalizes and adds a – between each word. If I can find a function or at minimum where the slug is created by the name and modify the code so that it then insert the hierarchy that would be great. Example being, if I had a parent called X and I create a sub attribute name Y, leave the slug field empty and click add, woo would create a slug name x-y automatically.
If someone can point me towards where this code might be found in the woocommerce directory.
- The topic ‘Hierarchy Slug’ is closed to new replies.