Tag Archives: WordPress Theme

How to Build a Great WordPress Site Using the Twenty Fourteen Theme

With its latest 3.8 “Parker” update a couple of months ago WordPress released a new default theme, Twenty Fourteen. The developers called it a “beautiful magazine theme,” emphasizing its strong visual elements, which make Twenty Fourteen stand out in comparison with the platform’s prior native themes. The bold new approach to the default design meant that the theme won’t work for every site or satisfy every user’s taste, but that didn’t seem to be the idea behind it. It looks like with every new theme, WordPress developers attempt to showcase a different aspect of the content management system, and Twenty Fourteen did just that in showcasing what WordPress can do for magazine-style sites and blogs.

Continue reading

How to Create a Tabbed Featured Post Area in WordPress

In this article I’ll show you how to Create a Tabbed Featured Post Area in WordPress. There are many themes that have built in tabbed featured post area. Also there are many plugins to show the tabbed featured post in specific area too. But each of them may have some lackings with your project requirement. So you may want to create your own hand coded tabbed featured post area in your existing theme. Continue reading

How to Customize WordPress’s Admin Login Logo

By default the WordPress’s admin login looks like the following:

WordPress Admin Login Screen

If you want to change the logo to customize it then add the following piece of code to the “functions.php” file of your WordPress theme:

add_action('login_head', 'wp_custom_login_logo');
function wp_custom_login_logo()
echo '<style type="text/css">';
echo 'h1 a { background-image:url('.get_bloginfo('template_directory').'/images/my-logo.gif) !important; }';
echo '</style>';

Make sure to upload your custom logo (my-logo.gif) to the “images” directory of your wordpress theme.

WordPress Theme Tweaking Cheat Seets

If you are trying to tweak or develop a WordPress theme then this post should help making your life a bit easier. This post has a list of all the WordPress functions that you can use from your theme’s template file.

Useful PHP Code for Header

<?php bloginfo(‘name’); ?> Title of the site
<?php wp_title(); ?> Title of the post or page
<?php bloginfo(‘stylesheet_url’); ?> The style.css file’s location
<?php bloginfo(‘pingback_url’); ?> Pingback URL for the site
<?php bloginfo(‘template_url’); ?> Location for the site’s theme files
<?php bloginfo(‘version’); ?> WordPress version for the site
<?php bloginfo(‘atom_url’); ?> Atom URL for the site
<?php bloginfo(‘rss2_url’); ?> RSS2 URL for the site
<?php bloginfo(‘url’); ?> Exact URL for the site
<?php bloginfo(‘name’); ?> Name of the site
<?php bloginfo(‘html_type’); ?> HTML version of the site
<?php bloginfo(‘charset’); ?> Charset parameter of the site
<?php bloginfo(‘description’); ?> Site’s description

Useful PHP Code for the Body

<?php the_content(); ?> Content of the posts or page
<?php if(have_posts()) : ?> Checks if there are posts
<?php while(have_posts()) : the_post(); ?> Shows posts if posts are available
<?php endwhile; ?> Closes the ‘while’ PHP function
<?php endif; ?> Closes the ‘if’ PHP function
<?php get_header(); ?> Header.php file’s content
<?php get_sidebar(); ?> Sidebar.php file’s content
<?php get_footer(); ?> Footer.php file’s content
<?php the_time(‘m-d-y’) ?> The date in ’08-18-10′ format
<?php comments_popup_link(); ?> Link for the comments on the post
<?php the_title(); ?> Title of a specic post or page
<?php the_permalink() ?> Url of a specic post or page
<?php the_category(‘, ‘) ?> Category of a specic post or page
<?php the_author(); ?> Author of a specic post or page
<?php the_ID(); ?> ID of a specic post or page
<?php edit_post_link(); ?> Link to edit a specic post or page
<?php get_links_list(); ?> Links from the blogroll
<?php comments_template(); ?> Comment.php file’s content
<?php wp_list_pages(); ?> List of pages of the
<?php wp_list_cats(); ?> List of categories for the site
<?php next_post_link(‘ %link ‘) ?> Url to the next post
<?php previous_post_link(‘%link’) ?> Url to the previous post
<?php get_calendar(); ?> The built-in calendar
<?php wp_get_archives() ?> List of archives for the site
<?php posts_nav_link(); ?> Next and previous post link
<?php wp_loginout(); ?> Displays the login/logout link
<!–more–> Cuts off the content and adds a link to the rest of the content
<?php wp_meta(); ?> Meta for administrators

Other Useful PHP Functions

<?php timer_stop(1); ?> Time to load the page
<?php echo get_num_queries(); ?> Queries to load the page