-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.php
executable file
·48 lines (33 loc) · 1.05 KB
/
index.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
<?php
/**
* The main template file.
*
* @package QOD_Starter_Theme
*/
get_header(); ?>
<div id="primary" class="content-area">
<main id="main" class="site-main" role="main">
<div class="quote-area">
<?php
$args= array(
'posts_per_page' => '1',
'orderby' => 'rand',
);
$firstPost = new WP_Query($args);
while($firstPost-> have_posts()) : $firstPost -> the_post();
?>
<div class="quote"><?php the_content(); ?></div>
<p class="author"><?php the_title(); ?><p class = "source"></p></p>
<?php
// $firstAuthor = the_title();
// $firstQuote = the_content();
endwhile; ?>
<!-- <p class="quote"><?php// echo $firstQuote?></p>
<p class="author"><?php// echo $firstAuthor?></p> -->
<!-- <p class="quote">There are two ways to write error-free programs; only the third one works.</p>
<p class="author">Jorrin Bruns<p class = "source"></p> -->
<button class="new-quote">Show Me Another!</button>
</div>
</main><!-- #main -->
</div><!-- #primary -->
<?php get_footer(); ?>