Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <br/>
- <div align="center">
- <form class="form-wrapper" action="/" method="get">
- <input type="text" name="s" id="search" value="<?php the_search_query(); ?>" placeholder="Search for..." required>
- <input type="submit" value="go" id="submit">
- </form>
- </div>
- <br/>
- <?php if( is_front_page() && is_home() ) { ?>
- <div class="gl-title"><font color="#DD3333">⚡</font> Trending Now...</div>
- <?php
- $args = array(
- 'posts_per_page' => 8,
- 'post__in' => get_option( 'sticky_posts' ),
- 'ignore_sticky_posts' => 1
- );
- $my_query = new WP_Query( $args );
- $do_not_duplicate = array();
- while ( $my_query->have_posts() ) : $my_query->the_post();
- $do_not_duplicate[] = $post->ID; ?>
- <!--Pattern HTML-->
- <div id="pattern" class="pattern">
- <ul class="list img-list">
- <li>
- <a href="<?php the_permalink(); ?>" class="inner">
- <div class="li-img">
- <?php the_post_thumbnail(); ?>
- </div>
- <div class="li-text">
- <h4 class="li-head"><?php the_title(); ?></h4>
- </div>
- </a>
- </li>
- </ul>
- </div>
- <!--End Pattern HTML-->
- <?php endwhile; ?>
- <?php wp_reset_postdata(); //VERY VERY IMPORTANT?>
- <br/>
- <br/>
- <div class="gl-title"><font color="#DD3333">♫</font> Fresh Songs</div>
- <?php
- // the query
- $the_query = new WP_Query( array(
- 'category_name' => 'news',
- 'posts_per_page' => 5,
- ));
- ?>
- <?php if ( $the_query->have_posts() ) : ?>
- <?php while ( $the_query->have_posts() ) : $the_query->the_post(); ?>
- <!--Pattern HTML-->
- <div id="pattern" class="pattern">
- <ul class="list img-list">
- <li>
- <a href="<?php the_permalink(); ?>" class="inner">
- <div class="li-img">
- <?php the_post_thumbnail(); ?>
- </div>
- <div class="li-text">
- <h4 class="li-head"><?php the_title(); ?></h4>
- </div>
- </a>
- </li>
- </ul>
- </div>
- <!--End Pattern HTML-->
- <?php endwhile; ?>
- <?php wp_reset_postdata(); ?>
- <?php else : ?>
- <p><?php __('No News'); ?></p>
- <?php endif; ?>
- <div style="width: 91%; padding: 10px; margin: 8px; border: 1px solid #d1d1d1; background: #fff;" align="right">
- <a href="/category/news" class="gl-more-songs"><font color="#fff">Load more songs...</font></a>
- </div>
- <br/>
- <div class="gl-title"><font color="#DD3333">♨</font> Latest Updates</div>
- <?php } else { ?>
- <?php if ( is_archive() ) { ?>
- <h2 class="heading-font archive-title"><?php wptouch_fdn_archive_title_text(); ?></h2>
- <?php } ?>
- <?php } ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement