Add experience timeline Page Template #10
2 changed files with 110 additions and 110 deletions
|
@ -13,13 +13,13 @@
|
||||||
get_header(); ?>
|
get_header(); ?>
|
||||||
|
|
||||||
<?php
|
<?php
|
||||||
function withinDates( $jSDate, $jEDate ) {
|
function withinDates( $jSDate, $jEDate ) {
|
||||||
$endYear = date( 'Y' );
|
$endYear = date( 'Y' );
|
||||||
$endDate = $endYear . '-12-31';
|
$endDate = $endYear . '-12-31';
|
||||||
$startDate = ( $endYear - 2 ) . '-01-01';
|
$startDate = ( $endYear - 2 ) . '-01-01';
|
||||||
$jEDate = ( ! $jEDate ) ? date( 'Y-m-d' ) : ( ( $jEDate > $endDate ) ? $endDate : $jEDate );
|
$jEDate = ( ! $jEDate ) ? date( 'Y-m-d' ) : ( ( $jEDate > $endDate ) ? $endDate : $jEDate );
|
||||||
return ( ( ( strtotime( $jSDate ) < strtotime( $endDate ) ) && ( strtotime( $jSDate ) > strtotime( $startDate ) ) ) && ( strtotime( $jEDate ) > strtotime( $startDate ) ) );
|
return ( ( ( strtotime( $jSDate ) < strtotime( $endDate ) ) && ( strtotime( $jSDate ) > strtotime( $startDate ) ) ) && ( strtotime( $jEDate ) > strtotime( $startDate ) ) );
|
||||||
}
|
}
|
||||||
$args = array(
|
$args = array(
|
||||||
'post_type' => array(
|
'post_type' => array(
|
||||||
'job',
|
'job',
|
||||||
|
@ -27,7 +27,7 @@ get_header(); ?>
|
||||||
'posts_per_page' => -1,
|
'posts_per_page' => -1,
|
||||||
);
|
);
|
||||||
$loop = new WP_Query( $args );
|
$loop = new WP_Query( $args );
|
||||||
?>
|
?>
|
||||||
|
|
||||||
<div id="experience-wrapper" class="content-area col-10 col-m-12">
|
<div id="experience-wrapper" class="content-area col-10 col-m-12">
|
||||||
<header class="post-header-title">
|
<header class="post-header-title">
|
||||||
|
|
Reference in a new issue