Exemple #1
0
<?php

/**
 * The template for displaying the third featured category on homepage.
 * Gets the category id from the theme options. 
 *
 * @file      feat_cat3.php
 * @package   max-magazine
 * @author    Sami Ch.
 * @link 	  http://gazpo.com
 */
?>
 

<?php 
$cat3_id = max_magazine_get_option('feat_cat3');
$cat3_name = get_cat_name($cat3_id);
$cat3_url = get_category_link($cat3_id);
?>



<div class="category">

	<h3 class="cat-title"><a href="<?php 
echo esc_url($cat3_url);
?>
" ><?php 
echo $cat3_name;
?>
</a></h3>
Exemple #2
0
<!-- Modal -->
<div class="modal fade in" id="myModal" tabindex="-1" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true">
  <div class="modal-dialog">
    <div class="modal-content">
      <div class="modal-header">
        <?php 
if (max_magazine_get_option('logo_url')) {
    ?>
        
          <img src="<?php 
    echo max_magazine_get_option('logo_url');
    ?>
" alt="<?php 
    bloginfo('name');
    ?>
" width="200px" />      
        <?php 
}
?>
      </div>
      <div class="modal-body">
          <h4>Minore di 18 anni</h4>
          <?php 
echo get_option('xvp_code_vm_popup');
?>
      </div>
      <div class="modal-footer">
        <a href="javascript:window.open('','_self').close();" class="btn btn-lg btn-danger">Esci</a>
        <button type="button" class="btn btn-lg btn-primary"  data-dismiss="modal">Entra</button>
      </div>
    </div>
Exemple #3
0
<?php

/**
 * The template for displaying the first featured category on homepage.
 * Gets the category id from the theme options. 
 *
 * @file      feat_cat1.php
 * @package   max-magazine
 * @author    Sami Ch.
 * @link 	  http://gazpo.com
 */
?>
 

<?php 
$cat1_id = max_magazine_get_option('feat_cat1');
$cat1_name = get_cat_name($cat1_id);
$cat1_url = get_category_link($cat1_id);
?>



<div class="category">

	<h3 class="cat-title"><a href="<?php 
echo esc_url($cat1_url);
?>
" ><?php 
echo $cat1_name;
?>
</a></h3>
Exemple #4
0
		

		<!--<?php 
if (max_magazine_get_option('ad468')) {
    ?>






			<!--<div class="ad468">	

				<?php 
    echo max_magazine_get_option('ad468');
    ?>
	

			</div>-->

		<?php 
}
?>
 


		

	</div><!-- /wrap -->
Exemple #5
0
            get_template_part('includes/feat_cat4');
        }
        ?>
			
					</div> <!-- /featured-categories -->
				
			<?php 
    }
}
//is_home
//include latest posts
if (max_magazine_get_option('show_posts_list') != 0) {
    get_template_part('includes/content');
}
//no option is set in the homepage, display posts list.
if (max_magazine_get_option('show_slider') == 0 and max_magazine_get_option('show_feat_cats') == 0 and max_magazine_get_option('show_carousel') == 0 and max_magazine_get_option('show_posts_list') == 0) {
    ?>
				<div class="no-posts-notice">
					<?php 
    _e('Please enable theme settings from the theme options', 'max-magazine');
    ?>
				</div>
				<?php 
    get_template_part('includes/content');
    ?>
			
			<?php 
}
?>
		
</div><!-- /content -->
							<?php 
        }
        ?>
						
					</div><!-- /post-meta -->
			
					<div class="post-entry">
						<?php 
        the_content();
        ?>
				
					</div><!-- /post-entry -->
							
				</div><!-- post -->
				<?php 
        if (max_magazine_get_option('show_page_comments') == 1) {
            ?>
					<?php 
            comments_template('', true);
            ?>
				<?php 
        }
        ?>
			<?php 
    }
    ?>
 
		
			<?php 
    if ($wp_query->max_num_pages > 1) {
        ?>
Exemple #7
0
							<?php 
        }
        ?>
		
						</div>
							
					</div><!-- /post-meta -->
			
					<div class="post-entry">
						<?php 
        the_content();
        ?>
				
					</div><!-- /post-entry -->
					<?php 
        if (max_magazine_get_option('show_author') == 1 and get_the_author_meta('description') != '') {
            ?>
					            
						<div class="author">	
								
							<h3><?php 
            _e('About the author', 'max-magazine');
            ?>
</h3>
								<?php 
            if (function_exists('get_avatar')) {
                echo get_avatar(get_the_author_meta('email'), '50');
            }
            ?>
							<div class="author-meta">
								<div class="name"><?php 
Exemple #8
0
<?php

/**
 * The template for displaying the carousel posts.
 * Gets the category for the posts from the theme options. 
 * If no category is selected, displays the latest posts.
 *
 *
 * @file      footer.php
 * @package   max-magazine
 * @author    Sami Ch.
 * @link 	  http://gazpo.com
 *
 */
$carousel_cat_id = max_magazine_get_option('carousel_category');
//if no category is selected for carousel, show latest posts
if ($carousel_cat_id == 0) {
    $post_query = 'posts_per_page=10';
} else {
    $post_query = 'cat=' . $carousel_cat_id . '&posts_per_page=10';
}
?>

<div id="carousel">
	<div class="title">
		
		<div class="cat">
			<h3>
				<?php 
if ($carousel_cat_id == 0) {
    _e('Latest Posts', 'max-magazine');
				
				<div class="parent-post-link">
					<a href="<?php 
echo get_permalink($post->post_parent);
?>
" title="<?php 
printf(__('Return to %s', 'max-magazine'), esc_html(get_the_title($post->post_parent), 1));
?>
" rev="attachment"><span class="meta-nav">&laquo; </span><?php 
echo get_the_title($post->post_parent);
?>
</a>
				</div>
		
            </div><!-- /post --> 
			
			<?php 
if (max_magazine_get_option('show_media_comments') == 1) {
    ?>
				<?php 
    comments_template();
    ?>
			<?php 
}
?>
			
	</div>	<!-- /content -->
	
<?php 
get_sidebar();
get_footer();
<?php

/**
 * The template for displaying the second featured category on homepage.
 * Gets the category id from the theme options. 
 *
 * @file      feat_cat2.php
 * @package   max-magazine
 * @author    Sami Ch.
 * @link 	  http://gazpo.com
 */
?>
 
<?php 
$cat2_id = max_magazine_get_option('feat_cat2');
$cat2_name = get_cat_name($cat2_id);
$cat2_url = get_category_link($cat2_id);
?>

<div class="category">
	<h3 class="cat-title"><a href="<?php 
echo esc_url($cat2_url);
?>
" ><?php 
echo $cat2_name;
?>
</a></h3>
	
		<div class="feat-post"> 
			<?php 
$post_query = 'cat=' . $cat2_id . '&posts_per_page=1';
Exemple #11
0
<?php

/**
 * The template for displaying the forth featured category on homepage.
 * Gets the category id from the theme options. 
 *
 * @file      feat_cat4.php
 * @package   max-magazine
 * @author    Sami Ch.
 * @link 	  http://gazpo.com
 */
?>
 

<?php 
$cat4_id = max_magazine_get_option('feat_cat4');
$cat4_name = get_cat_name($cat4_id);
$cat4_url = get_category_link($cat4_id);
?>



<div class="category">

	<h3 class="cat-title"><a href="<?php 
echo esc_url($cat4_url);
?>
" ><?php 
echo $cat4_name;
?>
</a></h3>
<?php

/**
 * The template for the slider on homepage.
 * 
 * @file      feat_cat1.php
 * @package   max-magazine
 * @author    Sami Ch.
 * @link 	  http://gazpo.com
 **/
$slider_cat_id = max_magazine_get_option('slider_category');
//if no category is selected for slider, show latest posts
if ($slider_cat_id == 0) {
    $post_query = 'posts_per_page=5';
} else {
    $post_query = 'cat=' . $slider_cat_id . '&posts_per_page=5';
}
?>

<div id="slider">
	<div class="lof-slidecontent">	
	<div class="preload"><div></div></div>    		 
            <div class="main-slider-content">
                <ul class="sliders-wrap-inner">
					<?php 
query_posts($post_query);
?>
					
					<?php 
if (have_posts()) {
    ?>