Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- /**
- * @package GeneratePress
- */
- ?>
- <article id="post-<?php the_ID(); ?>" <?php post_class(); ?> <?php generate_article_schema( 'BlogPosting' ); ?>>
- <div class="inside-article">
- <?php do_action( 'generate_before_content'); ?>
- <header class="entry-header">
- <?php $value = get_post_meta($post->ID, 'job_status', true); ?>
- <?php if($value == 'open') { ?>
- <h2><?php the_title(); ?></h2>
- <?php } elseif($value == 'closed') { ?>
- <h2 style="text-decoration:line-through;"><?php the_title(); ?></h2>
- <p style="font-weight:700;color:red;">This job is closed and no longer available</p>
- <p>Look for more jobs by <a href="<?php echo get_author_posts_url( get_the_author_meta( 'ID' ) ); ?>"><?php the_author(); ?></a> »</p>
- <?php } else { ?>
- <p>?? <?php the_title(); ?> ??</p>
- <p style="font-weight:700;color:red;">The status of this job is unknown!</p>
- <p>You need <a href="<?php echo get_author_posts_url( get_the_author_meta( 'ID' ) ); ?>">contact <?php the_author(); ?></a> to find out if this job is available or not.</p>
- <?php } ?>
- </header><!-- .entry-header -->
- <?php do_action( 'generate_after_entry_header'); ?>
- <div class="entry-content" itemprop="text">
- <?php $value = get_post_meta($post->ID, 'job_status', true); ?>
- <?php if($value == 'open') { ?>
- <?php the_content(); ?>
- <ul>
- <li>School<span></span>: <?php the_author(); ?></li>
- <li>School level: <?php the_category(); ?></li>
- <li>First day: <?php the_date('l jS F Y'); ?></li>
- <li>Last Day: <?php $date = get_post_meta($post->ID, 'date-time-last', true); if($date != ''){echo date("l jS F Y", strtotime($date));} ?></li>
- <li>Duration: <?php if(has_term('', 'job_duration')) {?><?php echo strip_tags (get_the_term_list( $post->ID, 'job_duration', ' ',', ')); ?><?php } else { ?> at least one day<?php }?></li>
- <li>Year level/s: <?php if(has_term('', 'school-year-level')) {?><?php echo get_the_term_list( $post->ID, 'school-year-level', ' ',', '); ?><?php } else { ?> unknown year level/s<?php }?></li>
- <li>Learning areas: <?php if(has_term('', 'school-learning-area')) {?><?php echo get_the_term_list( $post->ID, 'school-learning-area', ' ',', '); ?><?php } else { ?> unknown learning areas<?php }?></li>
- <li>Subjects/Topics: <?php the_tags(); ?></li>
- </ul>
- <?php } elseif($value == 'closed') { ?>
- <?php } else { ?><?php } ?>
- <h3 style="float:left;"><a href="<?php echo get_author_posts_url( get_the_author_meta( 'ID' ) ); ?>" ><i class="fa fa-info-circle"></i> school info</a></h3>
- <?php /*
- <p style="float:right;"><a href="<?php echo get_author_posts_url( get_the_author_meta( 'ID' ) ); ?>" rel="author">subscribe to all jobs by this school <i class="fa fa-inbox" ></i></a></p>
- */ ?>
- <?php
- wp_link_pages( array(
- 'before' => '<div class="page-links">' . __( 'Pages:', 'generate' ),
- 'after' => '</div>',
- ) );
- ?>
- </div><!-- .entry-content -->
- <?php do_action( 'generate_after_entry_content'); ?>
- <!-- <footer class="entry-meta">
- <?php /* generate_entry_meta(); */ ?>
- <?php /* generate_content_nav( 'nav-below' ); */ ?>
- <?php /* edit_post_link( __( 'Edit', 'generate' ), '<span class="edit-link">', '</span>' ); */ ?>
- </footer>.entry-meta -->
- <?php do_action( 'generate_after_content'); ?>
- </div><!-- .inside-article -->
- </article><!-- #post-## -->
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement