Tell us what you are trying to do?
Hi guys, so I will explain:
- I have a custom User Role of 'Customer'
- Due to the restraints of 'Users' in WordPress and my need to apply multiple custom fields and relationships to users, I also have a custom post type of 'Customer'. When I setup a user which is a 'Customer', I have some custom code which then applies the email address to my 'Customer' Custom Post Type (the email being the Title field of my Customer), which then allows me to populate the Customer CPT with other custom fields, within the Customer Custom Post Type. (Hope this makes sense so far!)
- I also have another custom User Role of 'Staff', these are basically people who work for my clients company who will be able to log into WordPress and to add / edit / remove Customer users.
- I wanted for 'Customer' users to have a 'Company' field (so Customer A works for Company B for example), but due to me potentially having lots of users which could be part of the same Company, rather than set up 'Company' as a custom field, I set it up as a 'Custom Taxonomy', as I thought this would be more beneficial for development of the project going forward. That way I can easily link all 'Customers' who are part of the same 'Company', as this is a function which my client wanted for their website.
However, now this is where my problem has arisen:
- I am trying to build a Toolset 'View', accessible by 'Staff' users, which lists all 'Customers' users (so I am using a loop), along with various custom information which has been attributed to them (so as an example - each row of my view will show their Name, Age, Company, this is purely for example purposes and not exactly as in my View). Now, I am easily able to add custom fields to my view (in the example given Name and Age are custom fields), but their is no way for me to add the 'Company' to the view, as it is a Taxonomy and Taxonomies do not show up as an option in my View Builder. I have attached a screenshot where I explain this further.
Please can you tell me how I can load the Company Taxonomy for each user in my loop, for my View?
Thanks very much for your help,
Keith
Is there any documentation that you are following? There isn't any documentation I can find to tell me how to do this
Is there a similar example that we can see? No
What is the link to your site? It's under development, but I can provide URL's, Administrator logins etc if required, please just let me know if you need it 🙂