Showing posts with label WPBeginner. Show all posts
Showing posts with label WPBeginner. Show all posts

Wednesday, December 11, 2013

Best of Best WordPress Tutorials of 2013 on WPBeginner

Yet another year is about to come to an end. We want to thank you guys for supporting WPBeginner for 4+ years of our existence. As we look back at the year of 2013, it was full of success and joy for the WPBeginner team. With your help, we built a school, launched floating social bar, launched OptinMonster, and very recently launched the WPBeginner Glossary.


Over the course of the year, we wrote tons of WordPress tutorials. We thought we should compile a list of our favorite ones. Let’s do a year in review of WPBeginner.


January 2013


How to Add MP3 Audio Files in WordPress – When you add an MP3 audio file in WordPress, WordPress does not embed it to your blog posts and instead a link to download file is added to the post. In this article we showed you how to add MP3 audio files in WordPress oEmbed in an HTML5 media player.


How to Merge and Bulk Edit Categories and Tags in WordPress – A common problem that most WordPress users face at some point is to bulk edit categories and tags. This usually happens when you are not using them right (see our guide categories vs. tags). In this article we showed how to bulk edit categories and tags in WordPress and even merge them.


Why is WordPress Free? What are the Costs? What is the Catch? – One of the most commonly question asked about WordPress, is that Why is it free> In this article we explained exactly how WordPress is free, what are the costs associated with creating a WordPress site, and what’s the catch.


February 2013


Why You Should NOT Remove Dates from Your WordPress Blog Posts – A common misconception among users is that if they removed dates from their WordPress articles, search engines would think that date is not relevant to the article and it will always remain fresh. We debunked the myth and explained exactly why it is a bad idea to remove dates from your WordPress blog posts.


How to Track Links in WordPress using Google Analytics – Google Analytics has so many great features that can help you build your site, plan your content strategy and do a lot more. In this article we showed users how they can track links in WordPress using Google Analytics.


March 2013


How are WordPress.com and WordPress.org Related? – Sometimes users confuse WordPress (the software), with WordPress.com, the blog hosting service. In this article we explained the relationship between WordPress.org and WordPress.com.


How to Create Custom Taxonomies in WordPress – Custom taxonomies are a great way to sort your content with custom post types. In this tutorial we showed users how to create custom taxonomies in WordPress and how to use them.


April 2013


Beginner’s Guide to WordPress Database Management with phpMyAdmin – WordPress is written in PHP and uses MySQL as its database management system. To use WordPress you don’t need to learn either of them but a basic understanding of how WordPress stores data can help you troubleshoot problems easily. In this article we showed how WordPress stores data in your MySQL database and how you can manage your database using phpMyAdmin.


How to Add Additional User Profile Fields in WordPress Registration – The default WordPress user registration form is very basic. However, if you are running a a membership site or a multi-author WordPress blog, then you might want to give user the ability to provide extra information during the registration. In this tutorial we showed you how to add additional user profile fields in WordPress registration and user profiles.


May 2013


How to Import External Images in WordPress – When moving a WordPress site from one location to another, sometimes your image imports may fail. In this article we showed users how to search and import external images in WordPress. You can import them to your site and they will be available from your media library.


How to Install WordPress on your Windows Computer Using WAMP – The most efficient way to learn WordPress is to install it on your computer by creating a local server environment. We wrote this step by step guide to install WordPress on your Windows computer using WAMP.


How to Style Your WordPress Comments Layout – Comments are the soul of a good successful blog and online community. A great design for your comments section encourages users to submit comments. In this article we wrote about how to style your WordPress comments layout using the default css classes in WordPress.


June 2013


Best WordPress Magazine Themes of 2013 – WordPress is not just used by blogs, thousands of magazines, portals, and news sites are also running on WordPress with themes designed specifically for magazine websites. In this article we compiled a hand-picked list of the best WordPress magazine themes.


How to Properly Move WordPress to a New Domain Without Losing SEO – When moving your WordPress site to a new domain name, the most dreadful thing that can happen is to loose your site rankings and all its traffic. In this article we wrote about how to properly move your WordPress site to a new domain without losing SEO and traffic from other sources.


How to Add Affiliate Links in WordPress with ThirstyAffiliates – Affiliate marketing is a growing niche, it allows website owners to promote products on their website and earn commission. This extra revenue stream can provide a sustainable base to any online publication. In this article we showed our users how to add and manage affiliate links in WordPress with ThirstyAffiliates.


July 2013


How to Add a Floating Social Share Bar in WordPress – We have a floating social bar on our website which floats above the post area when a user scrolls down. We decided to release it as a plugin, Floating Social Bar. In this article we showed users how to add floating social share bar in WordPress.


We Built the School + WPBeginner Giveaway Winners – On WPBeginner’s fourth birthday we announced the largest WordPress giveaway ever, we also did fundraising to build a school and we were successful. In this article we announced the giveaway winners and our fundraising experience.


Beginner’s Guide: How to Restore WordPress from Backup – We advice our users to regularly backup their WordPress sites. Previously we showed you how to create a backup with BackupBuddy, BackWPup, and manual backups. In this article we showed users how to restore WordPress from a backup.


August 2013


5 Best Related Posts Plugins for WordPress – Displaying related posts with your articles is a great way to increase pageviews. You can display related posts in WordPress without a plugin. However, for our beginner users we compiled a list of 5 best related posts plugin for WordPress.


How to Fix Broken Links in WordPress with Broken Link Checker – If you are running a site for a long time, there is a good chance that you might have some links on your website that are not working anymore. Broken links cause a bad user experience and lots of broken links can also affect your site’s performance in search engines. In this article we showed you how to fix broken links in WordPress with Broken Link Checker.


How to Add or Remove Capabilities to User Roles in WordPress – WordPress comes with a powerful user management system which is based on roles and capabilities. The roles are easier to manage you can simply go to a user’s profile and assign them a role. Each roles comes with its own capabilities. In this article we showed users how they can add or remove capabilities to user roles in WordPress to create a customized user management system of their own.


September 2013


How to Build Your Email List in WordPress with OptinMonster – WPBeginner released OptinMonster in collaboration with Thomas Griffin Media. It is the best WordPress lead generation plugin, with beautiful optins to boost your email list subscriptions. In this article we showed how to build your email list in WordPress with OptinMonster.


How to Allow Users to Submit Posts to Your WordPress Site – Many of our readers asked us about how to allow users to submit posts to their WordPress sites without losing editorial and administrative control of their site. In this article we showed you how to allow users to submit posts to your WordPress site.


October 2013


How We Increased Our Email Subscribers by 600% with OptinMonster – We use OptinMonster as the lead generation plugin on our sites. This is the case study of how we increased our email subscribers by 600% with OptinMonster.


How to Create a Custom WordPress Widget – Widgets are the easiest way to add custom functions and features to your WordPress site’s sidebars or any widget-ready areas. In this article we showed users how to create a custom WordPress widget from scratch.


How to Disable Automatic Updates in WordPress – Since 3.7, WordPress comes with the ability to automatically update itself to a minor release. This was a cause of concern for many users who preferred to update their sites manually. In this article we showed how to disable automatic updates in WordPress.


November 2013


Which is the Best WordPress Slider? Performance + Quality Compared – There are many WordPress slider plugins out there. For new users this abundance of choice can be confusing. In this article we compared the most popular WordPress slider plugins for quality, features, user-friendliness to find out which is the best WordPress slider plugin.


Why You Should Start Building Your Email List Right Away – Many people who visit a website never return to it, there are lots of websites out there and it is hard to keep users coming back to your website. We have found that building an email list is the best way to keep users engaged. In this article we explained why you should start building your email list right away.


December 2013


Announcing WPBeginner Glossary – Dictionary of WordPress Terms We launched WPBeginner’s Glossary which lists commonly used WordPress terms and explains them to beginners. We were often asked by beginners to explain them common terms which were obvious to us but totally new to the people who never used WordPress before. This glossary will try to help those users.


How to Undo Changes in WordPress with Post Revisions – How to use post revisions in WordPress to undo changes and revert back to an earlier version of your WordPress posts and pages.


How to Fix the Image Upload Issue in WordPress – Many beginners face this file permission issue which prevents them from uploading their images in WordPress. This article shows how to fix that.


These were the best WordPress tutorials of WPBeginner in 2013. We hope that you liked them. We want to thank you for supporting us by sharing our articles, giving us feedback, and suggesting new topics. We would not be here without the support our community, so really thank you. We hope to add more useful tutorials in 2014.


To leave a comment please visit Best of Best WordPress Tutorials of 2013 on WPBeginner on WPBeginner.







via WPBeginner http://feeds.wpbeginner.com/~r/wpbeginner/~3/XIYDE5bZ0Dk/

WordPress Hosting Tips

Monday, December 9, 2013

How to Undo Changes in WordPress with Post Revisions

WordPress has built-in capability which allows you to undo changes and go back to an earlier version of a post. This feature is called Post Revisions or simply Revisions. When writing articles, most of us make mistakes. Sometimes you even wish that you hadn’t deleted what you wrote earlier. Revisions allow you to go back in time and undo any changes. In this article, we will show you how to undo changes in WordPress with post revisions.



For the text version keep reading below.


What is Post Revisions?


WordPress has a built-in system that stores a post as a revision on each auto save or when a user saves a post. The autosave feature in the WordPress post editor saves a post every 60 seconds as a special revision. Old auto saves are then replaced by new auto saved revisions. Each time a user clicks on the save, update, or publish button, a new revision is stored in your database.


You can see these revisions on your post edit screen or by browsing the revisions. Since WordPress 3.6, there is a new more intuitive way to browse your revisions that allows you to see the changes made in each revision and who made those changes. You can also browse through different revisions and revert back to any one of them if you want.


Will it delete my current revision? No, it will not delete your current version. Instead, your current version will be saved as another revision and you can revert back to it just like you reverted back to an earlier revision.


Why You Should Use Post Revisions


Almost every WordPress user can benefit from post revisions. Writing great content requires a lot of tweaking and re-writing. Post revisions allow you to see your process and take a bird’s eye view of how your post has evolved. You can then switch between different states of your draft, make changes, and make your article perfect for publishing.


For multi-author WordPress sites, post revisions allow editors to manage teams to work on a story or article at the same time. You can see who made changes to an article, what changes they made, and so on. Combine post revisions with Edit Flow and you got yourself a robust editorial platform.


How to use Post Revisions to Undo Changes in WordPress


WordPress displays the number of revisions for each post in the publish meta box on the post/page edit screen. Clicking on browse will take you to post revisions screen.


Revisions are displayed in publish meta box on WordPress post edit screen


You can also display revisions below post edit area by clicking on Screen Options and checking Revisions.


Displaying revisions in post edit area of WordPress admin


The post revision screen will you the latest revision of the post with scrollbar on top. Sliding the button on the scroll bar will take you to different revisions of your post. Changes made in each revision will be highlighted in green and pink colors. On the top you can see the user who made these changes, time, and other information. WordPress will also let you know if a revision is an autosave or a draft.


Post revisions screen in WordPress


You can also use next and previous buttons to move around revisions or check the box on top that says compare any two revisions. This will split the button scroll bar into two and you can take each button to a different revision and compare the difference between two distant revisions.


Comparing any two revisions in WordPress


To restore a revision simply click on Restore This Revision or Restore This Autosave button. WordPress will restore the selected revision as your current post revision and you can then save it as a draft.


Notification displayed after restoring a post from revision in WordPress


It is also possible for you to limit post revisions or even completely disable post revisions. However, we would strongly recommend against that because post revisions come in very handy in many situations. If you want you can delete old post revisions which you are sure that you will not need any more.


We hope that this article helped you understand how to use post revisions to undo changes in WordPress. Have you ever used post revisions? Let us know by leaving a comment below. Also don’t forget to subscribe to our Youtube Channel.


To leave a comment please visit How to Undo Changes in WordPress with Post Revisions on WPBeginner.







via WPBeginner http://feeds.wpbeginner.com/~r/wpbeginner/~3/1UrC1h84zto/

WordPress Hosting Tips

Friday, December 6, 2013

How to Use Masonry to Add Pinterest Style Post Grid in WordPress

This is a guest post by Josh Pollock


The Pinterest-like grid display of posts has been a popular design for WordPress blog index pages for a while. It is popular not only because it mimics the look of the popular social media site, but also because it makes the best use of space on the screen. On a WordPress blog index, it allows each post preview to be the size it naturally needs to be, without leaving extra space.


In this tutorial, I will show you how to use the popular Masonry JavaScript Library to create cascading grid layouts for your blog index, as well as archive pages for your theme. I will address a few issues that you need to consider for mobile-optimization and how to solve them.


Screenshot of Masonry Grid Layout in WordPress


Note: This is an advanced level tutorial for those who feel comfortable editing WordPress themes and have sufficient HTML/CSS knowledge.


Step 1: Add Necessary Libraries To Your Theme


Before we begin, you will need to get two files, both by David DeSandro and add them to your theme’s JS directory. The first is Masonry 3, and the second is ImaglesLoaded, which will allow us to have Masonry delay calculating the grid layout until it has all the image sizes it needs, which is important to avoid certain layout issues.


WordPress includes Masonry 2, but has not been updated to version 3 as of WordPress 3.7. As a result we will need to deregister the included Masonry, something that I would normally never do, but there is nothing I can do about it. As you will see in the function below we are only adding Masonry 3 to the front-end, not the admin, where the included Masonry is essential.


Here is the function and action for adding the two libraries, along with a style sheet for Masonry:



if (! function_exists('slug_scripts_masonry') ) :
if ( ! is_admin() ) :
function slug_scripts_masonry() {
//deregister built in masonry since it is old version 3.
wp_deregister_script('jquery-masonry');
wp_enqueue_script('imagesLoaded', get_template_directory_uri().'/js/imagesloaded.pkgd.min.js', false, null, true);
wp_enqueue_script('jquery-masonry', get_template_directory_uri().'/js/masonry.pkgd.min.js', array( 'imagesLoaded'), null, true );
}
wp_enquqe_style('masonry’, get_template_directory_uri().'/css/’);
add_action( 'wp_enqueue_scripts', 'slug_scripts_masonry' );
endif; //! is_admin()
endif; //! slug_scripts_masonry exists


One thing to notice is that for Masonry, we are passing the ‘imagesLoaded’ handle in the third parameter for wp_enqueue_scripts(), which is the dependency argument, (see our guide on how to properly add JavaScripts and Styles in WordPress). This will ensure that Masonry is always loaded after imagesLoaded, and will only be loaded when Masonry is loaded. Also note that we are not adding jQuery as a dependency for either. One of the advantages of Masonry 3 over, Masonry 2 is that it does not require jQuery, but can be used with it. In my experience, initializing Masonry without jQuery is more reliable, and opens up the possibility of skipping loading jQuery, which can help with both page load times and compatibility issues.


Step 2: Initialize The Javascript


This next function sets up Masonry, defines the containers that will be used with it and also makes sure everything happens in the right order. Masonry needs to do calculate the size of each of the items on the page in order to layout its grid dynamically. A problem I’ve run into with Masonry in many browsers is that Masonry will miscalculate the height of items with slow loading images, leading to overlapping items. The solution is to use imagesLoaded to prevent Masonry from calculating the layout until all images are loaded. This ensures proper sizing.


This is the function and action that will output the initialization script in the page footer:



if ( ! function_exists( 'slug_masonry_init' )) :
function slug_masonry_exists() { ?>
<script>
//set the container that Masonry will be inside of in a var
var container = document.querySelector('#masonry-loop');
//create empty var msnry
var msnry;
// initialize Masonry after all images have loaded
imagesLoaded( container, function() {
msnry = new Masonry( container, {
itemSelector: '.masonry-entry'
});
});
</script>
<?php }
//add to wp_footer
add_action( 'wp_footer', 'slug_masonry_init' );
endif; // ! slug_masonry_init exists

The function is explained step by step with inline comments. What the Javascript function does is tell Masonry to look inside a container with the id “masonry-loop” for items with the class “masonry-entry” and to calculate the grid only after images are loaded. We set the outer container with querySelector and the inner with itemSelector.


Step 2: Create Masonry Loop


Instead of adding the HTML markup for Masonry directly to a template we are going to create a separate template part for it. Create a new file called “content-masonry.php” and add it to your theme. This will allow you to add the Masonry loop to as many different templates as you want.


In your new file you will add the code shown below. The markup is similar to what you would normally see for any content preview. You can modify it anyway you need to, just be sure that the outermost element has the class of “masonry-entry” that we set as the itemSelector in the last step.



<article class="masonry-entry" id="post-<?php the_ID(); ?>" <?php post_class(); ?> >
<?php if ( has_post_thumbnail() ) : ?>
<div class="masonry-thumbnail">
<a href="<?php the_permalink(' ') ?>" title="<?php the_title(); ?>"><?php the_post_thumbnail('masonry-thumb'); ?></a>
</div><!--.masonry-thumbnail-->
<?php endif; ?>
<div class="masonry-details">
<h5><a href="<?php the_permalink(' ') ?>" title="<?php the_title(); ?>"><span class="masonry-post-title"> <?php the_title(); ?></span></a></h5>
<div class="masonry-post-excerpt">
<?php the_excerpt(); ?>
</div><!--.masonry-post-excerpt-->
</div><!--/.masonry-entry-details -->
</article><!--/.masonry-entry-->

This markup has classes for each of its parts so you can add markup to match your theme. I like adding a nice, slightly rounded border to .masonry-entry. Another nice option is no border for .masonry-entry, but to give it a slight shadow. That looks particularly good when the post thumbnail extends the whole way to the border of the container, which can be accomplished by giving .masonry-thumbnail margins and paddings of 0 in all directions. You will want to add all of these styles in a file called masonry.css in your theme’s css directory.


Step 3: Add Masonry Loop To Templates


Now that we have our template part you can use it in any template in your theme you like. You might add it to index.php, but not category.php if you don’t want it used for category archives. If you only want it used on your theme’s home page, when its set to show blog posts, you would use it in home.php. Wherever you choose all you need to do is wrap your loop in a container with the id “masonry-loop” and add the template part into the loop using get_template_part(). Be sure to start the masonry loop container before while (have_posts() ).


For example, here is the main loop from twentythirteen’s index.php:



<?php if ( have_posts() ) : ?>

<?php /* The loop */ ?>
<?php while ( have_posts() ) : the_post(); ?>
<?php get_template_part( 'content', get_post_format() ); ?>
<?php endwhile; ?>

<?php twentythirteen_paging_nav(); ?>

<?php else : ?>
<?php get_template_part( 'content', 'none' ); ?>
<?php endif; ?>

And here it is modified to get use our Masonry loop:



<?php if ( have_posts() ) : ?>
<div id="masonry-loop">
<?php /* The loop */ ?>
<?php while ( have_posts() ) : the_post(); ?>
<?php get_template_part( 'content', 'masonry' ?>
<?php endwhile; ?>
</div><!--/#masonry-loop-->
<?php twentythirteen_paging_nav(); ?>

<?php else : ?>
<?php get_template_part( 'content', 'none' ); ?>
<?php endif; ?>

Step 4: Set Responsive Widths of Masonry Items


There are several ways that you can set the width of each Masonry item. You can set the width using a number of pixels when you initialize Masonry. I’m not a fan of doing that since I use responsive themes and it requires some complex media queries to get things right on small screens. For responsive designs, I’ve found the best thing to do is set a width value for .masonry-entry with a percentage, based on how many items you want in a row and let Masonry do the rest of the math for you.


All this requires is dividing the 100 by the number of items you want to set the percentage in a simple entry in your theme’s style.css. For example, if you want four items in each row you could do this in your masonry.css file:


.masonry-entry{width:25%}


Step 5: Mobile Optimization


We could stop here, but I don’t think the end-result works incredibly well on small phone screens. Once you’re happy with how your theme looks with the new Masonry grid on your desktop, check it out on your phone. If you’re not happy about how it looks on your phone, then you will need to do a little work.


I don’t think there is enough room on a phone’s screen for everything we added to our content-masonry template part. Two good solutions available to you are to shorten the excerpt for phones or skip it entirely. Here is an extra function you can add to your theme’s functions.php to do that. Because I don’t think these issues are a problem on tablets, I am using a great plugin Mobble in all of the examples in this section to only make the changes on phones, not tablets. I am also checking to see if Mobble is active before using it and if necessary falling back to the more general mobile detection function wp_is_mobile which is built into WordPress.



if (! function_exists('slug_custom_excerpt_length') ) :
function slug_custom_excerpt_length( $length ) {
//set the shorter length once
$short = 10;
//set long length once
$long = 55;
//if we can only set short excerpt for phones, else short for all mobile devices
if (function_exists( 'is_phone') {
if ( is_phone() ) {
return $short;
}
else {
return $long;
}
}
else {
if ( wp_is_mobile() ) {
return $short;
}
else {
return $long;
}
}
}
add_filter( 'excerpt_length', 'slug_custom_excerpt_length', 999 );
endif; // ! slug_custom_excerpt_length exists

As you can see we start by storing the long excerpt length and short excerpt length in variables, since we will be using those values twice and we want to be able to change them from one place if we need to later on. From there we test if we can use Mobble’s is_phone(). If so we set the short excerpt for phones and the long excerpt if we are not. After that we do the same basic thing, but using wp_is_mobile, which will affect all mobile devices ,if is_phone() can’t be used. Hopefully the else part of this function will never be used, but it’s good to have a backup just in case. Once the excerpt length logic is set it just comes down to hooking the function to the excerpt_length filter.


Shortening the excerpt is one option, but we can also do away with it entirely with a simple process. Here is a new version of content-masonry, with the entire excerpt portion ommited on phones:



<article class="masonry-entry" id="post-<?php the_ID(); ?>" <?php post_class(); ?> >
<?php if ( has_post_thumbnail() ) : ?>
<div class="masonry-thumbnail">
<a href="<?php the_permalink(' ') ?>" title="<?php the_title(); ?>"><?php the_post_thumbnail('masonry-thumb'); ?></a>
</div><!--.masonry-thumbnail-->
<?php endif; ?>
<div class="masonry-details">
<h5><a href="<?php the_permalink(' ') ?>" title="<?php the_title(); ?>"><span class="masonry-post-title"> <?php the_title(); ?></span></a></h5>
<?php
//put the excerpt markup in variable so we don't have to repeat it multiple times.
$excerpt = '<div class="masonry-post-excerpt">';
$excerpt .= the_excerpt();
$excerpt .= '</div><!--.masonry-post-excerpt-->';
//if we can only skip for phones, else skip for all mobile devices
if (function_exists( 'is_phone') {
if ( ! is_phone() ) {
echo $excerpt;
}
}
else {
if ( ! wp_is_mobile() ) {
echo $excerpt;
}
}
?>
</div><!--/.masonry-entry-details -->
</article><!--/.masonry-entry-->

This time we have are testing to see if we are not on a phone/ mobile device and if so we return the excerpt part of our loop. If we are on a phone/ mobile device we do nothing.


Another thing you might want to do is increase the width of the Masonry items, which reduces the number in a row, on mobile devices. In order to do this, we will add a different inline style to the header based on device detection. Since this function uses wp_add_inline_styles it will be dependent on a specific style sheet. In this case I’m using masonry.css, which you might want, for keeping your masonry styles separate. If you don’t end up using that you can use the handle from another, already registered stylesheet.



if ( ! function_exists ( 'slug_masonry_styles' ) ) :
function slug_masonry_styles() {
//set the wide width
$wide = '25%';
//set narrow width
$narrow = '50%';
/**Determine value for $width**/
//if we can only set narrow for phones, else narrow for all mobile devices
if (function_exists( 'is_phone') {
if ( is_phone() ) {
$width = $narrow;
}
else {
$width = $wide;
}
}
else {
if ( wp_is_mobile() ) {
$width = $narrow;
}
else {
$width = $wide;
}
}
/**Output CSS for .masonry-entry with proper width**/
$custom_css = ".masonry-entry{width: {$width};}";
//You must use the handle of an already enqueued stylesheet here.
wp_add_inline_style( 'masonry', $custom_css );
}
add_action( 'wp_enqueue_scripts', 'slug_masonry_styles' );
endif; // ! slug_masonry_styles exists


This function eneuques the custom stylesheet, and then sets a value for width using what should now be very familiar logic. After that we create the $custom_css variable by passing the value for width into an otherwise regular looking bit of CSS with {$width}. After that we use wp_add_inline_style to tell WordPress to print our inline styles in the header whenever the Masonry stylesheet is being used and then we hook the whole function to wp_enqueue_scripts and we are done.


If you chose to combine your Masonry styles into an existing stylesheet, be sure to use the handle of that style sheet with wp_add_inline_style or your inline styles will not be included. I like to use wp_add_inline_style because I generally wrap the action hook for enqueueing Masonry in a conditional so it only gets added when needed. For example if I am only using Masonry on my blog index and archive pages I would do this:



if ( is_home() || is_archive() ) {
add_action( 'wp_enqueue_scripts', 'slug_scripts_masonry' );
}


These last few examples should open up some other ideas in your brain. For example, you could use similar logic to skip Masonry altogether on a mobile device. Also wp_add_inline_style() is a lesser used, yet very helpful function as it allows you to programmatically set different styles based on any type of conditional. It can allow you to radically change the style of any element based on not only device detection, but the changes could also be based on which template is being used, or even if the user is logged in or not.


I hope you see these different changes I am making as an opportunity to get creative. Masonry and similar cascading grid systems have been popular for awhile now, so its time for some new twists on this popular idea. Show us in the comments what cool ways you’ve come up with for using Masonry in a WordPress theme.


A multi-purpose WordPress guy, Josh Pollock writes about WordPress, does theme development, serves as the community manager for the Pods Framework and advocates open source solutions for sustainable design.


To leave a comment please visit How to Use Masonry to Add Pinterest Style Post Grid in WordPress on WPBeginner.







via WPBeginner http://feeds.wpbeginner.com/~r/wpbeginner/~3/dK6pA16o6a0/

WordPress Hosting Tips

Thursday, December 5, 2013

How to Fix WordPress Post Pagination Hiding Content in RSS Feed

Recently one of our users complained to us about WordPress post pagination hiding the full content in their RSS feed. After doing a quick research, it turns out that this is a WordPress core bug (#10984) that was reported 4 years ago and is still not fixed. In this article, we will show you how to fix the WordPress post pagination hiding content in RSS feeds.


The problem occurs when you split your WordPress posts in multiple pages, and if you have set RSS feeds to display full text, then your RSS feeds will only display the content of the first page of the post (i.e before <!--nextpage--> tag).


Thankfully one of the contributors, Simon Wheatley, have posted a work around that fixes the bug.


All you need to do is add this code in your theme’s functions.php file or in a site-specific plugin:




function wpb_full_text_for_feeds( $content ) {
if ( ! is_feed() )
return $content;
global $post;
$content = $post->post_content;
return $content;
}

add_filter( 'the_content', 'wpb_full_text_for_feeds', -100 );


The above code adds a filter to the_content allowing the feeds to display full post content and ignoring the pagination (see more examples of how to add content in your RSS feeds). Hopefully this issue will get resolved soon in a future version of WordPress. Until then this workaround will make sure that your subscribers get the full content in their RSS reader.


We hope this article helped you fix WordPress post pagination issue in RSS feeds. Let us know what you think by leaving a comment below or join us on Twitter and Google+.


To leave a comment please visit How to Fix WordPress Post Pagination Hiding Content in RSS Feed on WPBeginner.







via WPBeginner http://feeds.wpbeginner.com/~r/wpbeginner/~3/rT528XuDej0/

WordPress Hosting Tips

Wednesday, December 4, 2013

How to Spread The Holidays Spirit with Your WordPress Site

Holiday season is upon us and the true spirit of the season is in spreading the joy to the people around us. We thought some of our users may want to spread the holiday spirit on their WordPress sites, so we found a few plugins and themes that can give your WordPress site the cheerful holiday look.


Christmas Ball on Branch


A very simple plugin that displays a Christmas ball on a branch in your site. There are no settings for the plugin. Simply install and activate it. The branch and the ball are displayed on the top-right corner of the screen. Particularly useful if you don’t want your on-site holiday decorations to take over the content.


Christmas ball on the branch


Holiday Message


Holiday Message allows you to add a holiday themed graphic with a custom message in a popup window.


You can choose where to display the pop-up, there are a number of positions available to choose from. The plugin also comes with Christmas, Hanukkah, and holiday themed graphics to choose from.


You can add your own message and greeting, add a count down timer, and even add snowfall effect. It uses cookies to display the popup only once, so your users will not be annoyed by it.


Holiday message


Holiday Snow


If you want to add the falling snow effect to your website, then you can install slimjetpack plugin. Slimjetpack is a stripped down version of the jetpack plugin. However, unlike Jetpack, You don’t need to sign up for a WordPress.com account to use this plugin.


Simply install and activate the plugin and then go to Settings » General. Scroll down to the bottom of the page and check the box next to Snow, to let it snow.


Let it Snow


Merry Christmas Everyone


Merry Christmas Everyone is a Christmas plugin with Santa Claus in it. If you were looking for something fun with Santa in it, then this is the plugin. There are two animated graphics of Santa Claus which will scroll on your pages. It also has a colorful snowfall feature and you can even add Christmas songs in the background.


Merry Christmas Everyone


WordPress Themes for Holidays


We usually do not favor changing a site’s design completely. But there are a couple of themes that we would like to mention here. In case you have a holiday themed website or blog, then you should take a look at these themes.


Spirit


Spirit is a beautiful holiday theme for a WordPress blog. Designed and illustrated by Caroline Moore, this beautiful theme has a Christmas tree in the background. There is snow and snow slakes falling as you scroll down the page.


Spirit - A Holiday Theme for your WordPress blog


Cheer


Cheer is a Christmas theme for WordPress blogs. As the name suggests it has a very cheerful look and feel to it with an elf sitting at the top. It comes in two color schemes and supports all the standard WordPress theme features.


Cheer - A Christmas theme for your WordPress blog


There are other ways to share the holidays spirit with your WordPress site. For example, if your theme has custom headers support, then you can add a header image with the seasonal theme or display a customized greeting with the sticky floating footer bar.


If you are using OptinMonster to display a lightbox Optin form, then you can add a holiday themed image or special offer to your optin.


We hope this article helped you do something joyful on your WordPress site during the holidays season. Let us know, what you are doing on your site by leaving a comment below.


To leave a comment please visit How to Spread The Holidays Spirit with Your WordPress Site on WPBeginner.







via WPBeginner http://feeds.wpbeginner.com/~r/wpbeginner/~3/RbxLD6Icp3s/

WordPress Hosting Tips

Tuesday, December 3, 2013

Announcing WPBeginner Glossary – Dictionary of WordPress Terms

Hello Everyone,


Syed Balkhi here. Today I’m proud to announce the launch of WPBeginner Glossary, a central place that lists and explain the most commonly used terminology in WordPress tutorials and WordCamp sessions.


If you were ever puzzled by strange WordPress terms or abbreviations, then this is the place to start. We did our best to explain WordPress lingo in plain english for WordPress beginners.


WPBeginner Glossary Banner


Where did the idea come from?


While speaking at the beginner workshop in WordCamp Columbus 2012, one of the attendees raised their hand and asked me this question:



“What is this widget thing that you’re talking about? It would be really nice if there was a dictionary that I can look up these WordPress lingo”



After my session, I sat down with her and answered a lot of her questions. Once I came back from the event, I completely forgot about the idea until earlier this year.


While organizing WordCamp Miami, several users came up to me and asked questions like what is a shortcode, what is a post type, etc.


That night I sat down and created an action plan for a WordPress glossary that explains WordPress terms in plain English.


After 6 busy months in which we built a school, launched floating social bar, redesigned List25, launched SteadyStrength, launched OptinMonster, I’m excited to announce that the WPBeginner Glossary is finally ready.


Currently the Glossary has a little over 100 terms, and we’re working on adding more.


Please check out our WordPress Glossary and let us know which terms you would like for us to add.


You can send us your term suggestions through the make a suggestion page.


We’re looking for volunteers to help contribute and improve the glossary. If you’re interested, then please send me a message or leave a comment below.


Last but not least, please help us spread the word by sharing this news with your friends on Twitter, Facebook, and Google+.


My goal is to continue to improve WPBeginner, and I hope a lot of you will find the glossary to be a helpful resource. If you have other suggestions on how I can improve WPBeginner, then you can reach out to me personally via my twitter @syedbalkhi


Yours Truly,

Syed Balkhi

Founder of WPBeginner


To leave a comment please visit Announcing WPBeginner Glossary – Dictionary of WordPress Terms on WPBeginner.







via WPBeginner http://feeds.wpbeginner.com/~r/wpbeginner/~3/izt1qLJvrIk/

WordPress Hosting Tips