Solution for Old WordPress Installation Not Allowing sub-directories in Network

Few days ago, I was trying to enable WordPress Network (Multisite) feature on one of my old WordPress site as WordPress 3.0 and above are having inbuilt (but hidden) Network feature. When I started that site, there was no need to have multiple sites with their own dashboard, posts, pages etc. but later on I thought to have different sites with one Network Admin control. This way I can let others manage different sites with different content and also monitor all of them with Network Admin control. The site was few months old and when I injected the below mentioned code in wp-config.php file to activate the Network, define('WP_ALLOW_MULTISITE', true); I got a message on network page saying, Because your install is not new, the sites in your WordPress network must use sub-domains. The main site in a sub-directory install will need to use a modified permalink structure, potentially breaking existing links. I was sure that I don’t need sub-domains for my new sites but I wanted sub-directories only. So that I can actually forward the backlinks and Google PageRank easily to my new sites. But since my site or say Installation was more than 1 month old, WordPress was not allowing to have sub-directories. The reason behind it is that when you opt for sub-directories, WordPress actually adds a term “/blog” at the start of your site’s permalink structure. And if you will enable the sub-directories structure of Network sites, you may break the old permalink structure and may lose old backlinks and Google PR juice. But as I was not using the site to get traffic from search engine, I was sure to have sub-directories only. Finally I got the simple solution to get that. So what is the solution? To have sub-directories structure on old WordPress installation while activating the Network feature, you just need to add the following code in your current theme’s functions.php file. add_filter( 'allow_subdirectory_install', create_function( '', 'return true;' ) ); That’s it. Now reload the Network page from Dashboard and you will see option to choose between sub-domain and sub-directory. Once you complete the Network activation process by adding the wp-config.php and htaccess code suggested on next page on Dashboard, you may remove the code from functions.php or even can change the theme template. I hope this simple tutorial helps you in getting sub-directory structure on WordPress Network site with old installation. Tip...

Read More

Authorship Markup rel=”author” tag coming with WordPress 3.2 in Twenty Ten, Twenty Eleven Themes and Core

Google has announced that they are going to support authorship markup i.e. rel=”author” tag in website’s html. It will be a way to tell the search engine about the author of the content. Based on the data, Google can organize the author’s content in their index system and let people browse that from search results. Google is also going to use this data in finding out the originality of the content. You can add this rel=”author” tag in WordPress theme template to showcase the author’s page. WordPress team has also started working on this task to add the tag by default in Twenty Ten and Twenty Eleven themes. These two themes are the default theme of WordPress. Twenty Eleven is coming with WordPress 3.2 where you will also see the Twenty Ten theme. WordPress is also going to add this tag in core files so that users can use the same in other themes. You can find the ticket on WordPress Trac for this task. It is still not clear whether this authorship markup is going to help in recovering from Google Panda update, but still it will be a good practice to add this markup in html. Are you a frequent guest blogger? If you are a frequent guest blogger and write for other websites too, then you should use rel=”me” on the guest blog site and provide the link to your website. Now use rel=”me” on your website’s profile page and provide the URL of the guest post saying that you have written this past as well. This way Google will know that the post was written by you only. Where to add the Markup in Theme? Wherever in the article you are mentioning the author’s name, just add the rel=”author” tag. For posts, the most common template file is single.php file. Try finding “author” in that template file and then you can add the rel tag over there. Now the link attached with the author’s name should go to the page where people can read something about the author and can also find posts written by the same person. The link should be from the same domain...

Read More