Quantcast
Channel: WordPress.org Forums » All Topics
Viewing all articles
Browse latest Browse all 210725

Add Job Listing Expiry

$
0
0

Replies: 0

Hi WP Job Manager,

I am not sure if this is a WC Paid Listings query or a WP Job Manager query. I have a form on my website at the frontend where people can fill up their details and add listings.

1. I want people to be able to change the expiry date of the listing in the form.
2. When the form is submitted, it should check if it’s less than 6 months or 12 months. It will return an error message if the value is not right.
3. I tried to add a custom field at the front end but my code is not working for some reason. What are the field types that are supported?
function frontend_add_expire_field( $fields ) {

$fields[‘job’][‘job_expires’] = array(
‘label’ => __( ‘Listing Expiry Date’, ‘job_manager’ ),
‘type’ => ‘date’,
‘required’ => true,
‘placeholder’ => ‘dd/mm/yyyy’,
‘class’ => array(‘expire’, ‘job-manager-datepicker’, ‘datepicker’,’timepicker’,’ui-timepicker-input’)
);
return $fields;
}

Are there any hooks to do these? I can’t find documentation anywhere in the web. Please help!

Xian


Viewing all articles
Browse latest Browse all 210725

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>