ACC SHELL
<?php
/**
* Šablona pro výpis kategorie.
*
* Používá se pro výpis příspěvků v kategorii
*
* @package WordPress
* @subpackage Laboserv
* @since Laboserv 0.1
*/
get_header(); ?>
<div id="main-content">
<?php if ( is_active_sidebar( 'header-2' ) ) : ?>
<!--<div id="header-2" class="widget-area" role="complementary">
<?php dynamic_sidebar( 'header-2' ); ?>
</div>-->
<?php endif; ?>
<?php if ( is_active_sidebar( 'sidebar-1' ) ) : ?>
<div id="left-sidebar" class="widget-area" role="complementary">
<?php if( is_user_logged_in() ) : ?>
<div id="zakaznicky-portal">
<h3>Zákaznický portál</h3>
<?php wp_nav_menu( array('menu' => 9) ); ?>
</div>
<?php endif; ?>
<?php dynamic_sidebar( 'sidebar-1' ); ?>
</div>
<?php endif; ?>
<div id="text-area" class="site-content no-right-sidebar">
<div id="content" role="main">
<div class="breadcrumbs">
<?php if(function_exists('bcn_display'))
{ bcn_display(); }
?>
</div>
<?php if ( have_posts() ) : ?>
<!--<header class="archive-header">
<h1 class="archive-title"><?php printf( __( 'Category Archives: %s', 'twentytwelve' ), '<span>' . single_cat_title( '', false ) . '</span>' ); ?></h1>
<?php if ( category_description() ) : // Show an optional category description ?>
<div class="archive-meta"><?php echo category_description(); ?></div>
<?php endif; ?>
</header>--><!-- .archive-header -->
<script>
actualID = 0;
function showContent(ID) {
if (actualID != 0) {
documentID = 'entry-content-post-' + actualID;
document.getElementById(documentID).style.display = 'none';
documentID = 'show-post-' + actualID;
document.getElementById(documentID).style.display = 'block';
documentID = 'entry-title-' + actualID;
document.getElementById(documentID).style.fontSize = '22px';
}
documentID = 'entry-content-post-' + ID;
document.getElementById(documentID).style.display = 'block';
documentID = 'show-post-' + ID;
document.getElementById(documentID).style.display = 'none';
documentID = 'entry-title-' + ID;
document.getElementById(documentID).style.fontSize = '34px';
actualID = ID;
}
</script>
<?php
/* Start the Loop */
while ( have_posts() ) : the_post();
/* Include the post format-specific template for the content. If you want to
* this in a child theme then include a file called called content-___.php
* (where ___ is the post format) and that will be used instead.
*/
get_template_part( 'content', get_post_format() );
endwhile;
twentytwelve_content_nav( 'nav-below' );
?>
<script>
actualID = <?php
$args = array('numberposts' => '5', 'category' => '8');
$last = wp_get_recent_posts($args);
echo $last['0']['ID'];
?>;
documentID = 'entry-content-post-' + actualID;
document.getElementById(documentID).style.display = 'block';
documentID = 'show-post-' + actualID;
document.getElementById(documentID).style.display = 'none';
documentID = 'entry-title-' + actualID;
document.getElementById(documentID).style.fontSize = '34px';
</script>
<?php else : ?>
<?php get_template_part( 'content', 'none' ); ?>
<?php endif; ?>
</div><!-- #content -->
</div><!-- #primary -->
<div class="clear"></div>
</div>
<?php
//get_sidebar();
?>
<?php get_footer(); ?>
ACC SHELL 2018