Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- /**
- * Template Name: Movies
- * Description: A template for displaying all movies.
- *
- * @package bootstrap-basic
- */
- get_header();
- $main_column_size = bootstrapBasicGetMainColumnSize();
- ?>
- <div class="page_banner">
- <div class="container">
- <h1 class="entry-title"><?php the_title(); ?></h1>
- <ol class="breadcrumb">
- <?php the_breadcrumb(); ?>
- </ol>
- </div>
- </div>
- <div id="main-container" class="container">
- <div class="page-box">
- <?php
- if ( have_posts() ) {
- while ( have_posts() ) {
- the_post();
- } // end while
- } // end if
- ?>
- <?php
- $args = array(
- 'post_type' => 'movies',
- );
- $movies = new WP_Query( $args );
- if( $movies->have_posts() ) {
- while( $movies->have_posts() ) {
- $movies->the_post();
- ?>
- <!--Start Event-->
- <div class="panel panel-default">
- <div class="panel-heading clearfix">
- <h3 class="panel-title pull-left"><?php the_field('movie_name'); ?></h3>
- <div class="btn-group pull-right">
- <?php
- if(get_field('movie_youtube'))
- {
- echo '<a href="' . get_permalink() . '" class="btn btn-md btn-success">Watch Trailer</a>';
- }
- ?>
- <a href="" data-toggle="modal" data-target="#myModal" class="btn btn-md btn-primary">Share</a>
- </div>
- </div>
- <div class="panel-body">
- <div class="col-md-9">
- <div class="blockquote-box">
- <div class="col-md-2">
- <img class='img-responsive' src="<?php the_field('thumbnail'); ?>"/>
- </div>
- <div class="col-md-10">
- <div class="description">
- <p><?php the_field('movie_description'); ?></p>
- </div>
- </div>
- </div>
- </div>
- <div style="text-align:center;border-left:1px solid #DDD;" class="col-md-3">
- <h4>Information</h4>
- <?php
- if(get_field('movie_showing'))
- {
- echo 'Showing:' . the_field('movie_showing');
- }
- ?>
- </div>
- </div>
- </div>
- <!--End Event-->
- <?php
- }
- }
- else {
- echo 'No movies found.';
- }
- ?>
- </div>
- </div>
- <?php get_footer(); ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement