Wordpress Technology

Wordpress Tips, Tutorials, Hacks

Highlight First Post

Archived; click post to view. Excerpt: Sometimes we have a need to highlight the first post in loop of main page, archive page or search page and apply different style for it. This output can be implemented by using special CSS class and simple php code. Originally we have the regular loop to output our […]

Add Content to RSS Feed

Code for inserting your own content to every RSS Feed of WordPress based blog is very simple It can be usefull for inserting ads or banners. Include the code must in functions.php of your theme.

Exclude Categories From RSS

If for some reasons we have to exclude one or several categories from RSS, it can be done this way. Insert into functions.php next code.

Posted in WordPress Hacks

Comments Off

Display Excerpt With Fixed Number of Words

We might have a situation, when we need to display the excerpt with the fixed number of world. To achieve that, create the next function in functions.php of the current theme:

Replace Content in All Posts

Let’s imagine we have to replace in all posts of wordpress the chunk of text at once, or highlite the word, or put the link, etc. To edit every post might take a long time. There is an elegant and simple solution to achieve the task.

List of The Most Commented Posts

Archived; click post to view. Excerpt: As you know the number of installed plugins affects the loading blog time. To display most commented posts without any plugin insert next code into template files (index.php, sidebar.php and so on.) 5 in line 2 is number of links displayed! Another Way Next code looks more elegant. <?php […]

Disable Default WordPress Widgets

To deactivate the unneccessary default WordPress Widgets just insert next code in your functions.php file of your current theme. The following code should be adjusted depending on your needs;

Remove Autolinks in Comments

To remove automatic links of urls in comments, simply open your functions.php file and paste the following code: Now you can say bye to to spammy links in comments.

Add Post Name to Body Class

Sometimes doing the css layout, we need to assign the specific class name to the body tag. To achieve the task, the only thing you have to do is to copy the following code and paste it on your theme functions.php file. Once saved, the post/page name will be automatically be added to the body […]

How to get sitename

How to get sitename

Posted in WordPress Tips

Comments Off

© 2009 | Made by Vancouver Web Design | Internet Marketing