-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.php
94 lines (82 loc) · 3 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
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
<?php
/**
* The main template file
*
* This is the most generic template file in a WordPress theme
* and one of the two required files for a theme (the other being style.css).
* It is used to display a page when nothing more specific matches a query.
* e.g., it puts together the home page when no home.php file exists.
*
* Learn more: {@link https://codex.wordpress.org/Template_Hierarchy}
*
* @package WordPress
* @subpackage Tween_Fift
* @since Tween Fift 1.0
*/
get_header(); ?>
<div id="primary" class="content-area">
<?php get_template_part( 'marqueetags' ); ?>
<main id="main" class="site-main" role="main">
<?php if ( have_posts() ) : ?>
<?php if ( is_home() && ! is_front_page() ) : ?>
<header>
<h1 class="page-title screen-reader-text"><?php single_post_title(); ?></h1>
</header>
<?php endif; ?>
<?php
// Start the loop.
while ( have_posts() ) : the_post();
/*
* Include the Post-Format-specific template for the content.
* If you want to override this in a child theme, then include a file
* called content-___.php (where ___ is the Post Format name) and that will be used instead.
*/
get_template_part( 'content', get_post_format() );
// End the loop.
//Show Anything After 2 Post
if( $wp_query->current_post == 1 ) { ?>
<!-- ADS 1 -->
<?php global $redux_tween_fift; $ads1 = $redux_tween_fift['ads-1']; if(($ads1 == '')) {
} else { ?>
<?php global $redux_tween_fift; $ads_switch1 = $redux_tween_fift['switch-ads-1']; if(($ads_switch1 == '1')) { ?>
<div class="ads">
<h3 class="title"><span>Advertisement</span></h3>
<div class="widget_ads">
<?php global $redux_tween_fift; echo $redux_tween_fift['ads-1']; ?>
</div>
</div>
<?php } else { } ?>
<?php } ?>
<?php }
//Show Anything After 2 Post END
//Show Anything After 4 Post
if( $wp_query->current_post == 3 ) { ?>
<!-- ADS 5 -->
<?php global $redux_tween_fift; $ads5 = $redux_tween_fift['ads-5']; if(($ads5 == '')) {
} else { ?>
<?php global $redux_tween_fift; $ads_switch5 = $redux_tween_fift['switch-ads-5']; if(($ads_switch5 == '1')) { ?>
<div class="ads">
<h3 class="title"><span>Advertisement</span></h3>
<div class="widget_ads">
<?php global $redux_tween_fift; echo $redux_tween_fift['ads-5']; ?>
</div>
</div>
<?php } else { } ?>
<?php } ?>
<?php }
//Show Anything After 2 Post END
endwhile;
// Previous/next page navigation.
the_posts_pagination( array(
'prev_text' => __( 'Previous page', 'tweenfift' ),
'next_text' => __( 'Next page', 'tweenfift' ),
'before_page_number' => '<span class="meta-nav screen-reader-text">' . __( 'Page', 'tweenfift' ) . ' </span>',
) );
// If no content, include the "No posts found" template.
else :
get_template_part( 'content', 'none' );
endif;
?>
</main><!-- .site-main -->
</div><!-- .content-area -->
<?php get_footer(); ?>