Toolonomy Logo

Add Custom Fields to The Frontend Job Submission Page of WP Job Manager

If you're using the WP Job Manager plugin for your job or any kind of listing site and looking for adding some custom fields on the front-end of the job submission page which is created using the [submit_job_form] default shortcode by WPJM then this post could be helpful for you.
Mohammed Wasim Akram
Blog Post Author
Last Updated: March 21, 2022
Blogpost Type:
0 Shares

If you're using the WP Job Manager plugin for your job or any kind of listing site and looking for adding some custom fields on the front-end of the job submission page which is created using the [submit_job_form] default shortcode by WPJM then this post could be helpful for you.

In this post, I am going to share with you a few custom-written PHP codes to add a custom text field to the job submission page of WP Job Manager.

You can add those codes within your functions.php file using your theme editor or you can use a plugin like Code Snippets, Scripts Organizer, or Advanced Scripts if you don't want to mess with the backend codes of the funtions.php file.

Add A Custom Text Field

To add a custom text field on the job submission page you would need to add this code to your website and in this section, I'll teach you how to customize the custom text field as per your requirement.

add_filter( 'submit_job_form_fields', 'frontend_add_Custom_Text_field' );
 function frontend_add_Custom_Text_field( $fields ) {
 $fields['company']['Custom_Text'] = array(
 'label' => __( 'Custom Text (Optional)', 'job_manager' ),
 'type' => 'text',
 'required' => false,
 'placeholder' => 'e.g. Add anything You Want',
 'priority' => 1,
 );
 return $fields;
 }

Step 1:

See carefully the very first line of the code where I have highlighted the text "Custom_Text" you just need to replace that thing with your own text, for example; add_filter( 'submit_job_form_fields', 'frontend_add_Date_of_Birth_field' );

Step 2:

Then you also need to replace the text from the second line of the code. As for example; function frontend_add_Date_of_Birth_field( $fields ) {

Step 3:

Then you need to change the same text on the third line of the code. As for example; $fields['company'][' Date_of_Birth '] = array(

One thing to keep in mind, if you add the field on the job application section then you just need to replace the company word from the job word in this line that's it. For example;
$fields[' job '][' Date_of_Birth '] = array(

Step 4:

Then on the fourth line also you need to replace the text from your own text as it's a label and will be visible on the front page thus you also should mention if the field is Required or Optional within the bracket.

As for example; 'label' => __( 'Date of Birth (Optional)', 'job_manager' ),

Step 5:

Then the next thing is to leave the 5th line of the code as it is because we are creating a custom text field thus it would be as text.

As for example; 'type' => 'text',

Step 6:

The 6th line should be left as it is if you want to keep this field optional but if you want to make this field required then you need to replace the word false with true.

As for example; 'required' => true,

Step 7:

The 7th line of the code is for a placeholder so you can add whatever you want to add on the placeholder, like in this placeholder you can indicate the format of date of birth.

As for example; 'placeholder' => 'e.g. 01.01.1990',

Step 8:

Then in the 8th line of the code select the priority or the position of the field on the page, like as you want to keep it on the top or in the below that you can decide in this line.

Here you just need to replace the number with your own number, suppose you want to keep this field below after 9 other fields then you have to replace the 1 with 10 on this line of code.

As for example; 'priority' => 10,

Conclusion

Nothing more you have to do once you have followed and made exact changes as I taught in this article.

Leave the rest of the code as it is and don't change any single thing from this code otherwise, nothing will work.

Once you have made the changes now you are ready to go, just add the code within your website using the functions.php or Code Snippets plugin and your custom text field is ready and live.

I hope I have been able to solve your problem regarding adding a custom text field on the job submission page of the WP job manager plugin.

If you face any difficulties to use this code then feel free to share your feedback in the comment box below or if you want me to add the custom fields for you then you can hire me for this job.

Thank you for visiting Toolonomy.com!

0 Shares
Toolonomy Online Community Image
Join Toolonomy Community
Toolonomy Community is a dedicated place to explore the Discussion, Content, Deals & Hidden Details about the Business Development Tools that have the potential to help you succeed in your journey to Digital Entrepreneurship by letting you build, manage, and grow your Business Online with ease.
Free Membership
A Google & HubSpot Certified Digital Marketing Specialist, Self-Taught WordPress Expert, Useful BizDev (Business Development) Tools & Deals Explorer, and the Founder of SyncWin & Toolonomy.
Subscribe
Notify of
guest
0 Comments
Inline Feedbacks
View all comments
Related Blog Posts
Explore all the other related blog posts.
WordPress
Best WordPress Table Builders: Top Free & Paid Plugins
As content creators when it comes to creating comparison posts inside WordPress, we need table builder plugins, so here I am presenting the best table builders loved and trusted by WordPress community. ...
WordPress
Best WordPress Anti-Spam Plugins
You might be wondering how can you keep your site safe from hackers and spammers, if yes then consider reading this post here I shared the top five plugins that can save your brand reputation from getting hamppered...
Artificial Intelligence
Best ChatGPT Addons: Handpicked Free Google Browser Extensions
In this article, you will discover some of the very useful and unique add-ons for ChatGPT which have the potential to enhance your workflow while using this AI-powered chatbot application....
Explore Blog

Become a Toolonomy Community Member for Free!

Consider joining our Official Community Group if you want to get access to exclusive insider content and information about Exclusive Digital Products and Technologies. Also, you will be able to get involved in interesting group discussions with like-minded people that are interested in similar topics as you.
Free Membership
Made with ❤ for Digital Product Enthusiasts
Copyright © 2018 - 2023 by SyncWin | All Rights Reserved.
Top crossmenu
0 Shares
Copy link