August 21st, 2010 By WP Tricks Posted in Tips
How To Enhancer Your WordPress authentication and added better handled and criteria. John Kolbert, one of WordPress developer create some tutorial how to do it. On this tutorial John Kolbert try to added same parameter and made own criteria…

WordPress Authentication - Miranda Kerr Black Leather
John using add_filter method to create it. He tweak original function of wp_authenticate. On this example John add new parameter that will denied username bob.
Read the rest of this entry »
Tags: add_filter, authentication, wp_authenticate
1 Comment
July 14th, 2010 By WP Tricks Posted in Tricks
If you are WordPress fanatics, there is some reason why we need to added extra classes on some WordPress standard code. Example we need adding extra classes and other attributes on previous_post_link() and next_post_link().

Adding Classes In WordPress - Anri Sugihara
To do this WP Tricks, we need to create some function on our functions.php, the function we need is to added the code with add_filter method. Follow this tricks
add_filter('next_posts_link_attributes', 'posts_link_attributes');
add_filter('previous_posts_link_attributes', 'posts_link_attributes');
function posts_link_attributes()
{
return 'class="styled-button"';
}
Read the rest of this entry »
Tags: add_filter, Classes, Functions, Tweak
No Comments
March 30th, 2010 By WP Tricks Posted in Tips
Why we need to Force CSS changes to “go live” immediately? As Web / WordPress designer we are even found some terrible problem. The problem is about internet / proxy cache in our system or ISP (Internet Services Provider) this is terrible bad news, if we develop/designed this site in live server.

Force Reload CSS in WordPress - Cansei Der Se Sexy
One way to solve this is to “version” your CSS file, by adding ?v=123 to the URL in the
to your stylesheet. This is rather a pain to have to do by hand every time, so here is a much better way
That’s what Mark Jaquith said on their blog, so to avoid and Force CSS changes we need to put some code in our style.css, so he we go to do this
<link rel="stylesheet" href="<?php bloginfo('stylesheet_url'); echo '?' . filemtime( get_stylesheet_directory() . '/style.css'); ?>" type="text/css" media="screen, projection" />
Read the rest of this entry »
Tags: add_filter, Cache, CSS, PHP, Proxy
2 Comments
March 28th, 2010 By WP Tricks Posted in Tricks
I will show you How to Change the Default Gravatar in WordPress, why? Because one of my favourite WordPress Comment enhancement is added Gravatar, after Gravatar become Automattic Family, Gravatar become more and more better. Especially integrated with many many Automattic Family, and of course WordPresss too.

The Right Way to Change The Default Gravatar in WordPress
Why changed the default (Misery Man) Gravatar? For me, it’s will make our website more unique and of course we can added extra banner or something in our Default Gravatar. Let’s get started, write down tiny code below in your theme functions.php
Change The Default Gravatar Code
add_filter( 'avatar_defaults', 'customgravatar' );
function customgravatar ($avatar_defaults) {
$myavatar = get_bloginfo('template_directory') . '/images/custom-gravatar.jpg';
$avatar_defaults[$myavatar] = "WP Tricks & Tips";
return $avatar_defaults;
}
Read the rest of this entry »
Tags: add_filter, Change, Code, Default, Gravatar
6 Comments
March 21st, 2010 By WP Tricks Posted in Tricks
My Another Favorite featured in WordPress is easy to tweak it out. And WordPress good support on Feed. Sometime we need to insert custom content into our WordPress Feeds right? On this post I will show you how to Insert Custom Content into Feeds. The custom content can be anything – text, markup, or even scripts – and may be set to appear in blog posts, feed posts, or both. You can easily set content to display before or after your post content, or in both places
Write down this code to Insert Custom Content into Feeds
function doContent($content) {
$content = $content . '<p class="extra">Write Down your custom content here!</p>';
return $content;
}
add_filter('the_excerpt_rss', 'doContent');
add_filter('the_content_rss', 'doContent');
Read the rest of this entry »
Tags: add_filter, Custom, Feed
2 Comments
Remove nofollow attributes from comment text
February 19th, 2010 By WP Tricks Posted in TipsWordPress added nofollow attributes on comment text url, this is bad for some commeter that needed some backlinks, if you want remove nofollow attributes from comment text in your WordPress site is easely, all need to do just added some code on functions.php on your theme and added some wordpress hooks using add_filter functions and your external url on comment text will be gone.
Write down to remove noffolow attributes on comment text below
function remove_nofollow($string) { $string = str_ireplace(' rel="nofollow"', '', $string); return $string; } add_filter('comment_text', 'remove_nofollow');And done, now you can check on your comment area with url and the nofollow attributes is gone
thanks for DigWP for share this code
Tags: add_filter, Comment, dofollow, Hooks, nofollow
18 Comments