WordPress.org

Forums

WP Job Manager
[resolved] Show Expiry Date (6 posts)

  1. lwyndham
    Member
    Posted 1 year ago #

    Does anyone know how to display the expiry date for both...

    A) the Single Job Listing template

    B) and for the Job listings [job] in a similar way it appears in the Job dashboard [job_dashboard]

    I image it has something to do with the template tag _job_expires but as of yet I have had no joy getting it to work.

    Any help will be much appreciated.

    Thanks!

    http://wordpress.org/plugins/wp-job-manager/

  2. Mike Jolley
    Member
    Plugin Author

    Posted 1 year ago #

    If you override the templates using this method https://github.com/mikejolley/WP-Job-Manager/wiki/Template-overrides you can add the date in there yourself.

    <?php echo ( $expires = get_post_meta( $post->ID, '_job_expires', true ) ) ? date_i18n( get_option( 'date_format' ), strtotime( $expires ) ) : '&ndash;'; ?>

  3. lwyndham
    Member
    Posted 1 year ago #

    Worked a treat - I'm very impressed by your excellent support.

    Thanks for your help and the great plugin!!!

  4. Mike Jolley
    Member
    Plugin Author

    Posted 1 year ago #

    Great! Feel free to leave a review :)

  5. shorif2000
    Member
    Posted 4 months ago #

    i have tried this but i cannot see a field called _job_expires. using the following in a template file
    <?php $custom_fields = get_post_custom( $post) ;print_r($custom_fields); ?>

    provides me with

    Array ( [_filled] => Array ( [0] => 0 ) [_featured] => Array ( [0] => 0 ) [_job_title] => Array ( [0] => UK Legal Counsel (Contract Manager and Business Support) ) [_job_location] => Array ( [0] => Woking, United Kingdom ) [_job_description] => Array ( [0] =>

  6. Mike Jolley
    Member
    Plugin Author

    Posted 4 months ago #

    It's only set when a job is published, based on the 'expirey' setting (days).

    p.s Please don't hijack other users threads, the moderators don't like that.

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic