«PREVIOUS 1 2 3 4 View All NEXT»
Hello and welcome all!
In this Guide, I will show you how you can develop plugins for the brand-spankin’-new latest version of WordPress 2.7.
What are we going to develop?
A Plugin, that will add “Topic Icons” inside the content of each post.
Hasn’t this already been done before?
Yes… yes it has been. It’s called “WP Post Icon” and you can find that plugin here at Linewbie’s WordPress Plugins Page
Then why re-invent the wheel?
So, let’s begin!
Step 0. Bare-Minimum Plugin Skeleton
In this step, we will cover the following:
- 1. Creating Commented Info Block
- 2. Creating Commented License Block
First, create a blank PHP file, name it content-icons.php, with the following content:
-
<?php
-
-
/*
-
Plugin Name: Content Icons
-
Plugin URI: http://www.codingrush.com/project-release/content-icons-plugin-release
-
Description: This plugin shows 'Content Icons' within each post. It is Compatible with WordPress 2.7. I have not tested this plugin with any other version of WordPress.
-
Version: 0.1
-
Author: RushiKumar Bhatt
-
Author URI: http://www.codingrush.com
-
*/
-
-
/*
-
Copyright 2009 RushiKumar Bhatt (email : RushiKumar dot bhatt at no spam dot gmail dot com)
-
-
This program is free software; you can redistribute it and/or modify
-
it under the terms of the GNU General Public License as published by
-
the Free Software Foundation; GNU GPL version 3 of the License.
-
-
This program is distributed in the hope that it will be useful,
-
but WITHOUT ANY WARRANTY; without even the implied warranty of
-
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-
GNU General Public License for more details.
-
-
You should have received a copy of the GNU General Public License
-
along with this program; if not, write to the Free Software
-
Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
-
*/
-
-
?>
Please make sure that there are no blank spaces before: <?php and after ?>. If there are any spaces, the WordPress will break, complaining that headers have already been sent.
Now, create a folder (preferably with the same name: content-icons) and place the newly-created php file inside it.
Next, upload the folder into the plugins directory:
Go to the admin area, and select “Plugins” menu option. Once there, you should see the following:

The comment block reflects what shows up in the plugins admin area
As you can see from the above snapshot, what we wrote for the comment block reflects here, in the Plugins Admin Area.
So, with our ‘bare-minimum’ skeleton out of the way, let’s make this functional, by adding key functionalities!
Popularity: 100% [?]
Posted by
Under
Tags: 
5 Comments Received
January 22nd, 2009 @5:38 am
Hi! A good forum, glad to join you
October 22nd, 2009 @2:29 am
Hi i read your code. It is very understandable way. But am getting error after activating this plugin.
Error: we cannot change the headers……
April 4th, 2010 @8:21 am
Hi Madhu,
Please provide more information. What version of WP are you running? Which file is it mentioning? Can you quote the error (Copy & Paste) ?
Pingback & Trackback
Leave A Reply