Browse: Home /
Tips & Tricks
Tips & Tricks
You are browsing the Tips & Tricks tag archive.
By Austin on June 24, 2009
Justin Tadlock has written a nice tutorial on how to show a password form field instead of the default text “There is no excerpt because this is a protected post“. ¶
Posted in Cult | Tagged Justin Tadlock, the_excerpt, Tips & Tricks
By Austin on May 15, 2009
Ever wanted to print or echo the WordPress title attribute without spaces?
Posted in Tips & Tricks | Tagged php, the_title, Tips & Tricks
By Austin on April 15, 2009
This is a simple one.
/**
* Your Blog title
*
*/
function my_blog_title() {
$blogname = get_bloginfo(‘name’);
return ‘<span class=”blog-title”>’ . $blogname . ‘</span>’;
}
add_shortcode(‘blog-title’, ‘my_blog_title’);
Just add this to your functions.php file and then add [blog-title] in any post or page and it will return your Blog Title.
Posted in Tips & Tricks | Tagged functions, shortcodes, Tips & Tricks
By Austin on March 1, 2009
Over the weekend, I attended WordCamp Denver, and I was asked by John Hawkins how to force links to open in a new tab with out editing the source code. So, today lets learn a simple jQuery trick to open all external links in your site in a new tab or window. We are going [...]
Posted in Tips & Tricks | Tagged CSS, jQuery, Tips & Tricks
By Austin on February 26, 2009
Hey everyone, as you may have noticed I have a running on the site. While everything almost everything moved over smoothly, there was an issue with how my parent theme striped text in typography. This caused some plugins, like cformsII to not be allowed to print to the screen. Justin had helped to find [...]
Posted in Themes, Tips & Tricks | Tagged functions, Hybrid Theme, Tips & Tricks
By Austin on February 15, 2009
In a previous post I showed you how to create a custom widget, then I showed you how to create a widget for your monthly archives, and limit the month’s that show. I am showing the past 4 months in my widget at this time.
One of my readers: Alex asked:
How did you make the archives [...]
Posted in Tips & Tricks | Tagged CSS, How to, li, Question, Tips & Tricks, ul
By Austin on February 10, 2009
I was asked by a reader:
I’m using the THiCK theme for my new design blog. I noticed you were able to add thumbnail images above your blog posts on the home page. What would I need to do to enable this on my blog?
Well Jon, this can be done very simple, since the theme is [...]
Posted in Themes, Tips & Tricks | Tagged THiCK, Tim Thumb, Tips & Tricks, Woo Themes
By Austin on February 4, 2009
This is an easy one, just add one line to your single.php file where you would like the Gravatar to show up.
<?php echo get_avatar( get_the_author_id(), $size = ‘96′, $default = ‘<path_to_url>’ ); ?>
Posted in Tips & Tricks | Tagged author, get_avatar, Gravatar, php, Tips & Tricks
By Austin on February 2, 2009
Want to show what any user was searching for?
It is simple, just add this line where your title would be.
<h1>Browsing search results for <strong>”<?php the_search_query() ?>”</strong>.</h1>
The important line is the_search_query()
Posted in Tips & Tricks | Tagged Search, the_search_query, Tips & Tricks
By Austin on January 30, 2009
In this post I will show you how I created my custom widget showcasing mybloglog readers.
In your function.php file add this simple line of code:
<?php
// MyBlogLog
function MyBlogLogWidget()
{
?>
<script type=”text/javascript” src=”http://pub.mybloglog.com/comm2.php?mblID=ReplaceWithYourID&c_width=220&c_sn_opt=n&c_rows=6&c_img_size=h&c_heading_text=&c_color_heading_bg=e0e0d4&c_color_heading=E8A02C&c_color_link_bg=e0e0d4&c_color_link=d54e21&c&c_color_bottom_bg=e0e0d4″></script>
<?php }
//register the sidebar ‘the widget name’, ‘the widget function’//
register_sidebar_widget(‘MyBlogLog Widget’, ‘MyBlogLogWidget’);
?>
That’s it, just replace the “ReplaceWithYourID” with your mybloglog ID. You can also change the [...]
Posted in Tips & Tricks | Tagged How to, MyBlogLog, Tips & Tricks, widget
By Austin on January 19, 2009
Ever wanted to display the title of a post somewhere but limit the amount of characters that are shown? For instance, this post has a very long title, and if I were to use <?php echo the_title() ?> it would show as follows: Limit the characters that display on the_title.
That may not fit well on [...]
Posted in Tips & Tricks | Tagged php, the_title, Tips & Tricks, WordPress
Add the twittar plugin for WordPress w/ comment threading
By Austin on February 18, 2009
I talked about the Twittar plugin in a previous post. But learned that the read me text file was only useful for installing the necessary php code into WordPress themes that don’t have comment threading enabled.
Since most new themes past version 2.7, pull the comments section from functions.php file, that is where you have to [...]
Posted in Plugins, Tips & Tricks | Tagged Plugins, Threaded Comments, Tips & Tricks, Twittar, WordPress