-
Notifications
You must be signed in to change notification settings - Fork 0
/
single-service.php
65 lines (51 loc) · 1.46 KB
/
single-service.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
<?php
get_header(); ?>
<?php if ( have_posts() ) : ?>
<?php while ( have_posts() ): the_post(); ?>
<main role="main">
<section class="services--single container">
<div class="services--content">
<h2><?php the_title(); ?></h2>
<?php the_content(); ?>
</div>
<div class="services--back">
<?php
$approach_link = get_permalink( get_page_by_path( 'approach' ) );
echo do_shortcode( '[button link="'.$approach_link.'" class="alt round-yellow back"]' . "Back to Approach" . '[/button]' );?>
</div>
</section>
<section class="container approach-services">
<h4>We implement a broad array of diversity resources and interventions</h4>
<ul class="link-list">
<?php
$args = array(
'post_type' => 'service',
'order' => 'ASC',
'orberby' => 'menu_order',
'numberposts' => '-1'
);
$services = get_posts($args);
foreach ($services as $service) : ?>
<?php
if ( !empty( $service->post_content ) ) { ?>
<li class="linked">
<a href="<?php echo get_permalink($service->ID); ?>">
<?php echo $service->post_title; ?>
</a>
<span class="link-list--corner"></span>
</li>
<?php
} else { ?>
<li>
<span class="link-list--item--no-link"><?php echo $service->post_title; ?></span>
</li>
<?php
}
endforeach;
?>
</ul>
</section>
</main>
<?php endwhile; ?>
<?php endif; ?>
<?php get_footer();