Skip to main content

Posts

Showing posts with the label WordPress Hacks

Using Multiple Permalink in WordPress

There time when you feel that the basic permalink settings of wordpress simply isn't enough when you want to make your url more meaningful and seo friendly. But how do we do this? There no much information on this out there as this is not something that all needs. Well, there is a very cool plugin out there that does exactly what you want. It's called   Advanced Permalinks The plugin provides advanced permalink options that allow you to: Have multiple permalink structures. Permalinks can be assigned to posts or ranges of posts 301 redirect old permalink structures (many structures are allowed) Category-specific permalinks. Posts in certain categories can be assigned a permalink structure No need to have a base to the category permalink! Change author permalinks Enable periods in permalinks - perfect for migrating old websit es.

Get popular posts by comments counts

Big the biggest challenge of blogger is to retain readers in their blog. One of the best technique to do this showing the most popular posts or related posts on the site where user is bound to see it. Keep this just below the current post may increase the chance of user seeing it. The reason to choose popular ones is because there might be a reason for it to be popular. So the chance for the reader like it is more. Getting the Popular Post Just copy & paste this piece of code where you want the list to display: $pop = $wpdb->get_results("SELECT id, post_title, comment_count FROM {$wpdb->prefix}posts WHERE post_type='post' ORDER BY comment_count DESC LIMIT 10"); foreach($pop as $post) : ?> post_title; ?>