I want to bring wp-job manager fields under Types Field Control. I've checked all relavant posts and my issue is exactly the same as this support post
https://toolset.com/forums/topic/cant-take-control-of-the-cpt-and-custom-fields-of-wp-job-manager/
The last post by support person Adriano refres to a technique but he says "Unfortunately, I don't think there is a way to remove the definition of those fields as they come with a plugin."
Does this mean it's impossible to access with the wp-job manager plugin fields in total?
If there is no technique for the above is it possible to create custom shortcodes for specific fields and register them so they can be used in "Fields and Views" part of the editor?
Thanks,
Ethan
This is Adriano's last comment on this topic:
Hello Lars,
You are right. Well, reading our documentation about that: https://toolset.com/faq/how-do-i-convert-existing-custom-types-and-fields-to-types-control/
You could see that the first thing you must do is:
Remove the PHP that declared these custom types. Normally, you’ll remove them from functions.php in the theme. Once you do this, all your custom data will appear to have vanished. Don’t worry. It just doesn’t show.
Unfortunately, I don't think there is a way to remove the definition of those fields as they come with a plugin.
Please let me know if you are satisfied with my reply and any other questions you may have.
Regards,
Adriano Ferreira
Hi Ethan,
Thank you for contacting us and I'd be happy to assist.
To suggest the best way forward, I'll need some specific details
1. Can you please share exactly which fields from "WP Job Manager" plugin are you planning to use?
2, Which Toolset features/operations would you like to use with those fields?
3. Will, you (admin) be adding/updating the data in those "WP Job Manager" plugin fields, only from the admin area (i.e. single post edit screen ) or will there be any front-end form for visitors too?
Based on these answers, I'll be happy to perform some tests on my website and suggest a possible workaround, accordingly.
regards,
Waqar
Hi Wagar,
You guys are one of the best support teams in the WorldPress universe. Thanks!.
1. Can you please share exactly which fields from "WP Job Manager" plugin are you planning to use?
Fields from the “Job Data” fields set
Company Name
Location
Company Tagline
Taxonomy Job Categories
Taxonomy Job Regions
Taxonomy Job Type
Some of these fields and taxonomy are part of their premium add-on plugins. Please advise if you need any copy from me.
2, Which Toolset features/operations would you like to use with those fields?
I use Views and content templates to make front end cards from posts.
I would like to create custom page single and archive templates too.
3. Will, you (admin) be adding/updating the data in those "WP Job Manager" plugin fields, only from the admin area (i.e. single post edit screen ) or will there be any front-end form for visitors too?
Both this plugin has front end features for submitting resumes and jobs
hidden link
hidden link
Thanks again Wagar,
Ethan
Hi Ethan,
You're very welcome and appreciate your kind words.
Thank you for these details and I'll be performing some tests on my website with "WP Job Manager" plugin, based on the requirements you've shared.
Will update you with my findings, once this testing completes.
Have a nice weekend.
regards,
Waqar
Hi Ethan,
Thank you for sharing these details.
With the involvement of premium add-ons, it would help if you could share a clone of any test website where all these fields are available.
Here is a guide on how to sharing a clone/snapshot:
https://toolset.com/faq/provide-supporters-copy-site/
Note: Your next reply will be private.
regards,
Waqar
Hi Ethan,
Thank you for sharing these files and I'm checking the fields from the premium add-ons now.
Will update you with my findings, shortly.
regards,
Waqar
Hi Ethan,
Thank you for waiting and here are my findings.
1. It is possible to fetch the data from the "WP Job Manager" plugin's custom fields and taxonomies, using Toolset Views shortcodes "wpv-post-field" ( ref: https://toolset.com/documentation/user-guides/views-shortcodes/#wpv-post-field ) and "wpv-post-taxonomy" ( ref: https://toolset.com/documentation/user-guides/views-shortcodes/#wpv-post-taxonomy ), respectively.
For example, you can use these shortcodes to show the values from the fields that you've mentioned, in Toolset views and content templates like this:
<strong>Company Name:</strong> [wpv-post-field name="_company_name"]<br>
<strong>Location:</strong> [wpv-post-field name="_job_location"]<br>
<strong>Company Tagline:</strong> [wpv-post-field name="_company_tagline"]<br>
<strong>Taxonomy Job Categories:</strong> [wpv-post-taxonomy type="job_listing_category" separator=", " format="link" show="name" order="asc"]<br>
<strong>Taxonomy Job Regions:</strong> [wpv-post-taxonomy type="job_listing_region" separator=", " format="link" show="name" order="asc"]<br>
<strong>Taxonomy Job Type:</strong> [wpv-post-taxonomy type="job_listing_type" separator=", " format="link" show="name" order="asc"]<br>
2. You can also use a Toolset Views content template to show the content of a single job post, by following these steps:
a). Please copy "content-single-job_listing.php" file from the plugin's directory ( wp-content/plugins/wp-job-manager/templates ) and place it inside a new folder named "job_manager" inside your active child theme's folder.
b). In that copied file, replace the content:
global $post;
?>
<div class="single_job_listing">
.........................
</div>
With:
global $post;
echo do_shortcode('[wpv-post-body view_template="slug-of-the-content-template"]');
?>
Note: Please replace the "slug-of-the-content-template" with an actual slug of the content template that you'd like to use.
I hope this helps and please let me know if you need any further assistance around this.
regards,
Waqar
Hi Waqar,
Thanks - this will be a great solution but I'm having issues with it still.
I'm getting "double" output of each field, separated by a comma. This happens both in loops and page single. Page single is easiest to reproduce on your end and demonstrate.
Picture "Toolset Admin"
I have only one company name "Boblattey Sports Company" and One Location "National Assembly Street, Phnom Penh, Cambodia". You can see the shortcodes added to the content section.
Picture "Toolset Front"
Each of the fields is repeated with a comma separating the two.
Do you get same on your end?
Thank you!
Ethan
Update: I tried creating a brand new job post and the double issue does not occur. I am guessing it must be double data in my database from an import/export post-migration issue. I will investigate more on my end. Thank you!
Hi Ethan,
Thanks for the update and glad that you found my suggestions useful.
Duplicate custom field entries would explain this and in your website's clone, I do see two entries against the key "_company_name" (and others), in "Freelance Writer" post.
( screenshot: hidden link )
Note: you can include the following code in your active theme's "functions.php" file, to see the hidden custom fields, on the post edit screen ( these are the fields for which the key starts with an underscore "_" )
add_filter( 'is_protected_meta', '__return_false', 999 );
Please let me know if you need any further assistance around this and you're welcome to start a new ticket for each new question or concern.
regards,
Waqar
My issue is resolved now. Thank you! Thank you very much. A great solution and the extra techniques you taught me were very helpful.