Forum Replies Created

Viewing 7 replies - 1 through 7 (of 7 total)
  • It would be also interesting for me.
    I show number of articles and comments, and also i will show the likes.

    <li><?php $nr_art = wp_count_posts('post'); $nr_art = $nr_art->publish; echo number_format($nr_art, 0, '', '.'); ?> articles</li>
    <li><?php $nr_komm  = get_comment_count(); $nr_komm  = $nr_komm['approved']; echo number_format($nr_komm, 0, '', '.'); ?> comments</li>
    <li>??? likes</li>
    Thread Starter joshi

    (@joshi)

    Yes something via JetPack would be great. For future we need a connection between blogs.

    Thread Starter joshi

    (@joshi)

    Yes i like this and look for a similar option for self hosted blogs.

    I add a new sidebar with 3 columns, but i don´t know, what i have to write in the “style.css” in my child theme. Under this new sidebar, i use also the old sidebar with 2 columns.

    functions.php

    <?php
    /**
     * Register additional widget areas for front page.
     */
    function mytheme_widgets_init() {
    	register_sidebar( array(
    		'name' => __( 'Third Front Page Widget Area', 'twentytwelve' ),
    		'id' => 'sidebar-4',
    		'description' => __( 'Appears when using the optional Front Page template with a page set as Static Front Page', 'twentytwelve' ),
    		'before_widget' => '<aside id="%1$s" class="widget %2$s">',
    		'after_widget' => '</aside>',
    		'before_title' => '<h3 class="widget-title">',
    		'after_title' => '</h3>',
    	) );
    
    	register_sidebar( array(
    		'name' => __( 'Fourth Front Page Widget Area', 'twentytwelve' ),
    		'id' => 'sidebar-5',
    		'description' => __( 'Appears when using the optional Front Page template with a page set as Static Front Page', 'twentytwelve' ),
    		'before_widget' => '<aside id="%1$s" class="widget %2$s">',
    		'after_widget' => '</aside>',
    		'before_title' => '<h3 class="widget-title">',
    		'after_title' => '</h3>',
    	) );
    
    	register_sidebar( array(
    		'name' => __( 'Fifth Front Page Widget Area', 'twentytwelve' ),
    		'id' => 'sidebar-6',
    		'description' => __( 'Appears when using the optional Front Page template with a page set as Static Front Page', 'twentytwelve' ),
    		'before_widget' => '<aside id="%1$s" class="widget %2$s">',
    		'after_widget' => '</aside>',
    		'before_title' => '<h3 class="widget-title">',
    		'after_title' => '</h3>',
    	) );
    }
    add_action( 'widgets_init', 'mytheme_widgets_init' );
    ?>

    sidebar-front2.php

    <?php
    /**
     * The sidebar containing the second set of front page widget areas.
     *
     * If no active widgets in either sidebar, they will be hidden completely.
     *
     */
    /*
     * The widget area is triggered if any of the areas
     * have widgets. So let's check that first.
     *
     * If none of the sidebars have widgets, then let's bail early.
     */
    if ( ! is_active_sidebar( 'sidebar-4' ) && ! is_active_sidebar( 'sidebar-5' ) && ! is_active_sidebar( 'sidebar-6' ))
    	return;
    
    // If we get this far, we have widgets. Let do this.
    ?>
    <div id="tertiary" class="widget-area" role="complementary">
    	<?php if ( is_active_sidebar( 'sidebar-4' ) ) : ?>
    	<div class="third front-widgets">
    		<?php dynamic_sidebar( 'sidebar-4' ); ?>
    	</div><!-- .fourth -->
    	<?php endif; ?>
    
    	<?php if ( is_active_sidebar( 'sidebar-5' ) ) : ?>
    	<div class="fourth front-widgets">
    		<?php dynamic_sidebar( 'sidebar-5' ); ?>
    	</div><!-- .fifth -->
    	<?php endif; ?>
    
    	<?php if ( is_active_sidebar( 'sidebar-6' ) ) : ?>
    	<div class="fifth front-widgets">
    		<?php dynamic_sidebar( 'sidebar-6' ); ?>
    	</div><!-- .sixth -->
    	<?php endif; ?>
    </div><!-- #tertiary -->

    front-page.php

    <?php
    /**
     * Template Name: Front Page Template
     *
     * Description: A page template that provides a key component of WordPress as a CMS
     * by meeting the need for a carefully crafted introductory page. The front page template
     * in Twenty Twelve consists of a page content area for adding text, images, video --
     * anything you'd like -- followed by front-page-only widgets in one or two columns.
     *
     * @package WordPress
     * @subpackage Twenty_Twelve
     * @since Twenty Twelve 1.0
     */
    
    get_header(); ?>
    
    	<div id="primary" class="site-content">
    		<div id="content" role="main">
    
    			<?php while ( have_posts() ) : the_post(); ?>
    				<?php if ( has_post_thumbnail() ) : ?>
    					<div class="entry-page-image">
    						<?php the_post_thumbnail(); ?>
    					</div><!-- .entry-page-image -->
    				<?php endif; ?>
    
    				<?php get_template_part( 'content', 'page' ); ?>
    
    			<?php endwhile; // end of the loop. ?>
    
    		</div><!-- #content -->
    	</div><!-- #primary -->
    
    <?php get_sidebar( 'front2' ); ?>
    <?php get_sidebar( 'front' ); ?>
    <?php get_footer(); ?>

    How can i change the 2 columns in this new sidebar, into 3 equal columns?

    Forum: Fixing WordPress
    In reply to: Fontsize Tagcloud

    Thank you .. it works with 10.1 🙂

    Forum: Fixing WordPress
    In reply to: Fontsize Tagcloud

    I have follow code in the “widgets.php”:

    wp_tag_cloud('smallest=10&largest=10&unit=pt&number=30&format=flat&orderby=count&order=DESC&exclude=&include=');

    But 5 Tags are bigger or bold. I dont know why.
    My site: http://www.pixilla.de

Viewing 7 replies - 1 through 7 (of 7 total)