Close

Account

Documentation

Forum

Menu

job details page issue

  • Post count: 67
    huwcole
    July 7, 2016 at 7:29 am #21082

    hi
    I cannot work out how you add a Company Industry and a different Job Category.
    see this on your demo: http://jobplanet.jegtheme.com/job/head-of-talent-development/

    under Job & Company Detail you have:

    Company Industry
    Real Estate & Property

    and

    Job Category
    Education & Training

    when i add a new job i can see that you can add a category as primary, assuming that this is the top level category and the second selected category is the secondary.
    but for me this is not working. it only shows the primary selected category under Job Category on the page and Company Industry is empty

    see example: http://www.dev.concept14.de/job/web-entwickler-php-entwickler-schwerpunkt-magento/

    any ideas what i am doing wrong

    thanks

    Post count: 67
    huwcole
    July 9, 2016 at 10:04 am #21118

    ok I have worked it out.
    basically some of the information comes from the company details and the other information from the job details.

    I did not see this

    but what i have not worked out is why on the job’s page under job categories i can set one category as primary and then select another category. when saved it only shows the secondary and not the primary and then the secondary.

    is this a bug???

    Post count: 67
    huwcole
    July 9, 2016 at 10:33 am #21119

    i fixed the bug with the job categories only displaying one instead of all selected:

    original:
    <!– category –>
    <h5><?php _e(‘Job Category’, ‘jobplanet-themes’); ?></h5>
    <p>
    <?php
    $category = get_the_terms(get_the_ID(), ‘job-category’);
    if(!empty($category)) {
    echo esc_html($category[0]->name);
    } else {
    echo esc_html(‘-‘);
    }
    ?>
    </p>

    replaced with this:

    <!– category –>
    <h5><?php _e(‘Job Category’, ‘jobplanet-themes’); ?></h5>
    <p>
    <?php
    $catarray = array();
    $categories = get_the_terms(get_the_ID(), ‘job-category’);
    if(!empty($categories)) {
    foreach($categories as $category) {
    $catarray[] = $category->name;
    }
    }
    if(!empty($catarray)) {
    echo esc_html( implode(‘, ‘, $catarray) );
    } else {
    echo esc_html(‘–’);
    }

    ?>
    </p>

    only thing it does not do is to show the primary first…

    Post count: 67
    huwcole
    July 9, 2016 at 10:37 am #21120

    forgot to mention which page it is I added the fix:

    wp-content\themes\jobplanet-themes\fragment\job-detail.php”

    line 129

    Post count: 2229
    Jegbagus
    July 12, 2016 at 2:51 am #21167

    hi huwcole, yes you can use your code. we also include your code to our next themes update.

    Thank you

You must be logged in to reply to this topic.