SlideShare a Scribd company logo
How to develop a plugin in
wordpress
With 6 easy simplest steps
by
Jay Bharat
1
Step1
• Close your eyes for 1 minute for take relax.
• Open your eyes
2
Step2
• Go to folder:
• wordpress/wp-content/plugins/
• Create a folder with any meaningful name.
• Create a file with any meaningful name under
newly creted folder as above.
• Example: /Users/jay/9844542127/im-mac-
desktop/php-mamp-wamp/wordpress/wp-
content/plugins/jayplugin
3
Step3
• Here I have created a file (jayplugin1.php)
inside my jayplugin folder
• See the screen shot in next page
4
5
Step4: write below code in newly
created file (here i.e: jayplugin1.php)
• <?
• /*
• Plugin Name: Jay WP Plugin Demo
• Plugin URI: http://www.bharatbaba.com
• Description: Tutorial for how to develope a plugin in wordpress
• Author: Jay Bharat/9844542127/jaybharatjay@gmail.com
• Version: 1.0/26-may-2015
• Author URI: http://www.bharatbaba.com
• */
• function limited_character_post( $limit ) {
• $content = explode( ' ', get_the_content(), $limit );
•
• if ( count( $content ) >= $limit ) {
• array_pop( $content );
• $content = implode(" ",$content).'...';
• } else {
• $content = implode(" ",$content);
• }
•
• $content = preg_replace('/[.+]/','', $content);
• $content = apply_filters('the_content', $content);
• return $content;
• }
• //code closed
6
• Screen shot for same as reference:
7
Step5
• Login as admin in wordpress
• Go to plugins section in admin panel
• You can see your plugin is appearing here with
name (as example here: Jay WP Plugin Demo)
• See the screen shot on above page
• Just click on activate
8
9
• I have activated it, see the screen shot below.
10
Step6
• This is the time to use your plugin for output.
• Go to index.php of your activated theme.
• Add this line:
• echo limited_character_post (10); // this line will display limited 10 chars long
• For example see the code screen shot and
output screen shot on next page.
11
• Code for display the code: echo limited_character_post(10); // this line will display limited 10 chars long
12
• Output as: Welcome to WordPress. This is your first post. Edit…
• This output coming from this function: limited_character_post
13
Note
• I am using : WordPress 4.2.2 helps you
communicate and share, globally.
• Above version
• But above tutorial will work almost all version.
• My current activated theme is: Twenty
Fifteen, but not matter it will work for all
designed theme.
• Thanks for attend.
14

More Related Content

What's hot (20)

PPT
Top 20 WordPress Plugins You've Never Heard Of
Brad Williams
 
PPT
Top 20 word press plugins you've never heard of
Toan Nguyen
 
PDF
No gEEk? No Problem!
carolinecblaker
 
PPT
Developing Plugins For WordPress
Lester Chan
 
PDF
Wordpress as a framework
Aggelos Synadakis
 
PPT
Getting Started With Wordpress
Digital Strategy Works LLC
 
PPTX
Jomc463 beginner wordpress(zeoli)
Digital Strategy Works LLC
 
ODP
Don't sh** in the Pool
Chris Jean
 
PPT
WordPress Plugins
OpenSource Technologies Pvt. Ltd.
 
PDF
So, you want to be a plugin developer?
ylefebvre
 
PPT
Word press Plugins by WordPress Experts
Yameen Khan
 
PDF
Ako na vlastne WP temy
Juraj Kiss
 
KEY
What is (not) WordPress
Nikolay Bachiyski
 
ODP
The Future Of WordPress Presentation
Dougal Campbell
 
KEY
Plugin Development Practices
danpastori
 
PDF
Mastering WordPress Vol.1
Wataru OKAMOTO
 
PPTX
Building a resposive slider plugin for WordPress theme
codebangla
 
PDF
WordCamp SF 2011: Debugging in WordPress
andrewnacin
 
PPT
Child Themes in WordPress
Jeff Cohan
 
PDF
Plugins at WordCamp Phoenix
Andrew Ryno
 
Top 20 WordPress Plugins You've Never Heard Of
Brad Williams
 
Top 20 word press plugins you've never heard of
Toan Nguyen
 
No gEEk? No Problem!
carolinecblaker
 
Developing Plugins For WordPress
Lester Chan
 
Wordpress as a framework
Aggelos Synadakis
 
Getting Started With Wordpress
Digital Strategy Works LLC
 
Jomc463 beginner wordpress(zeoli)
Digital Strategy Works LLC
 
Don't sh** in the Pool
Chris Jean
 
So, you want to be a plugin developer?
ylefebvre
 
Word press Plugins by WordPress Experts
Yameen Khan
 
Ako na vlastne WP temy
Juraj Kiss
 
What is (not) WordPress
Nikolay Bachiyski
 
The Future Of WordPress Presentation
Dougal Campbell
 
Plugin Development Practices
danpastori
 
Mastering WordPress Vol.1
Wataru OKAMOTO
 
Building a resposive slider plugin for WordPress theme
codebangla
 
WordCamp SF 2011: Debugging in WordPress
andrewnacin
 
Child Themes in WordPress
Jeff Cohan
 
Plugins at WordCamp Phoenix
Andrew Ryno
 

Viewers also liked (10)

PDF
Solr search engine with multiple table relation
Jay Bharat
 
PDF
My first WordPress Plugin
Abbas Siddiqi
 
PPTX
Introduction To Simple WordPress Plugin Development
Bruce L Chamoff
 
ODP
Facebook Social Plugins
Aizat Faiz
 
PDF
Social 101: Introduction to Google Buzz
Will Norris
 
ODP
Beginning WordPress Plugin Development
Aizat Faiz
 
PPT
How Not to Build a WordPress Plugin
Will Norris
 
PDF
Cache Money Business
Mark Jaquith
 
PDF
Writing Your First WordPress Plugin
Mark Jaquith
 
PDF
Object Oriented Programming for WordPress Plugin Development
mtoppa
 
Solr search engine with multiple table relation
Jay Bharat
 
My first WordPress Plugin
Abbas Siddiqi
 
Introduction To Simple WordPress Plugin Development
Bruce L Chamoff
 
Facebook Social Plugins
Aizat Faiz
 
Social 101: Introduction to Google Buzz
Will Norris
 
Beginning WordPress Plugin Development
Aizat Faiz
 
How Not to Build a WordPress Plugin
Will Norris
 
Cache Money Business
Mark Jaquith
 
Writing Your First WordPress Plugin
Mark Jaquith
 
Object Oriented Programming for WordPress Plugin Development
mtoppa
 
Ad

Similar to How to develope plugin in wordpress: 6 simple steps. (20)

PDF
5 Steps to Develop a WordPress Plugin From Scratch.pdf
BeePlugin
 
PPT
Wordpress Meetup 2 23 10
boonebgorges
 
PDF
Plugin Development for Beginners
Joe Cartonia
 
PPSX
Extending WordPress
Jonathan Bossenger
 
PDF
Test ss 2
dnunez0129
 
PDF
Write your first WordPress plugin
Anthony Montalbano
 
PPT
WordPress plugins
Christopher Ross
 
KEY
Intro to WordPress Plugins
zamoose
 
PPTX
WordPress plugin development
arryaas
 
PPT
WordPress Plugin Basics
Amanda Giles
 
PPTX
Intro to Plugin Development, Miami WordCamp, 2015
topher1kenobe
 
PPT
WordPress basic fundamental of plugin development and creating shortcode
Rakesh Kushwaha
 
PPTX
10 Things Every Plugin Developer Should Know (WordCamp Atlanta 2013)
arcware
 
PDF
Wordpress plugin
Harmanpreet Singh
 
PDF
Extending WordPress - a guide to building your first plugin
Jonathan Bossenger
 
PPT
Developing WordPress Plugins
rebelpixel
 
PPTX
Why & How to Create a WordPress Plugin
Joe Querin
 
PDF
Things to keep in mind while creating a word press plugin from scratch
Elsner Technologies Pvt Ltd
 
PDF
Plugin Development for Beginners v.2019
Joe Cartonia
 
KEY
How To Write a WordPress Plugin
Andy Stratton
 
5 Steps to Develop a WordPress Plugin From Scratch.pdf
BeePlugin
 
Wordpress Meetup 2 23 10
boonebgorges
 
Plugin Development for Beginners
Joe Cartonia
 
Extending WordPress
Jonathan Bossenger
 
Test ss 2
dnunez0129
 
Write your first WordPress plugin
Anthony Montalbano
 
WordPress plugins
Christopher Ross
 
Intro to WordPress Plugins
zamoose
 
WordPress plugin development
arryaas
 
WordPress Plugin Basics
Amanda Giles
 
Intro to Plugin Development, Miami WordCamp, 2015
topher1kenobe
 
WordPress basic fundamental of plugin development and creating shortcode
Rakesh Kushwaha
 
10 Things Every Plugin Developer Should Know (WordCamp Atlanta 2013)
arcware
 
Wordpress plugin
Harmanpreet Singh
 
Extending WordPress - a guide to building your first plugin
Jonathan Bossenger
 
Developing WordPress Plugins
rebelpixel
 
Why & How to Create a WordPress Plugin
Joe Querin
 
Things to keep in mind while creating a word press plugin from scratch
Elsner Technologies Pvt Ltd
 
Plugin Development for Beginners v.2019
Joe Cartonia
 
How To Write a WordPress Plugin
Andy Stratton
 
Ad

Recently uploaded (20)

PPTX
Stereochemistry-Optical Isomerism in organic compoundsptx
Tarannum Nadaf-Mansuri
 
PPTX
Pyhton with Mysql to perform CRUD operations.pptx
Ramakrishna Reddy Bijjam
 
PDF
LAW OF CONTRACT ( 5 YEAR LLB & UNITARY LLB)- MODULE-3 - LEARN THROUGH PICTURE
APARNA T SHAIL KUMAR
 
PDF
LAW OF CONTRACT (5 YEAR LLB & UNITARY LLB )- MODULE - 1.& 2 - LEARN THROUGH P...
APARNA T SHAIL KUMAR
 
PPT
Talk on Critical Theory, Part II, Philosophy of Social Sciences
Soraj Hongladarom
 
PPTX
How to Create Rental Orders in Odoo 18 Rental
Celine George
 
PDF
ARAL-Orientation_Morning-Session_Day-11.pdf
JoelVilloso1
 
PPTX
HYDROCEPHALUS: NURSING MANAGEMENT .pptx
PRADEEP ABOTHU
 
PDF
People & Earth's Ecosystem -Lesson 2: People & Population
marvinnbustamante1
 
PPT
Talk on Critical Theory, Part One, Philosophy of Social Sciences
Soraj Hongladarom
 
PDF
Zoology (Animal Physiology) practical Manual
raviralanaresh2
 
PDF
ARAL_Orientation_Day-2-Sessions_ARAL-Readung ARAL-Mathematics ARAL-Sciencev2.pdf
JoelVilloso1
 
PPTX
BANDHA (BANDAGES) PPT.pptx ayurveda shalya tantra
rakhan78619
 
PPTX
Soil and agriculture microbiology .pptx
Keerthana Ramesh
 
PPTX
How to Configure Access Rights of Manufacturing Orders in Odoo 18 Manufacturing
Celine George
 
PDF
'' IMPORTANCE OF EXCLUSIVE BREAST FEEDING ''
SHAHEEN SHAIKH
 
PPSX
Health Planning in india - Unit 03 - CHN 2 - GNM 3RD YEAR.ppsx
Priyanshu Anand
 
PPTX
Unit 2 COMMERCIAL BANKING, Corporate banking.pptx
AnubalaSuresh1
 
PPTX
How to Manage Promotions in Odoo 18 Sales
Celine George
 
PPTX
Quarter1-English3-W4-Identifying Elements of the Story
FLORRACHELSANTOS
 
Stereochemistry-Optical Isomerism in organic compoundsptx
Tarannum Nadaf-Mansuri
 
Pyhton with Mysql to perform CRUD operations.pptx
Ramakrishna Reddy Bijjam
 
LAW OF CONTRACT ( 5 YEAR LLB & UNITARY LLB)- MODULE-3 - LEARN THROUGH PICTURE
APARNA T SHAIL KUMAR
 
LAW OF CONTRACT (5 YEAR LLB & UNITARY LLB )- MODULE - 1.& 2 - LEARN THROUGH P...
APARNA T SHAIL KUMAR
 
Talk on Critical Theory, Part II, Philosophy of Social Sciences
Soraj Hongladarom
 
How to Create Rental Orders in Odoo 18 Rental
Celine George
 
ARAL-Orientation_Morning-Session_Day-11.pdf
JoelVilloso1
 
HYDROCEPHALUS: NURSING MANAGEMENT .pptx
PRADEEP ABOTHU
 
People & Earth's Ecosystem -Lesson 2: People & Population
marvinnbustamante1
 
Talk on Critical Theory, Part One, Philosophy of Social Sciences
Soraj Hongladarom
 
Zoology (Animal Physiology) practical Manual
raviralanaresh2
 
ARAL_Orientation_Day-2-Sessions_ARAL-Readung ARAL-Mathematics ARAL-Sciencev2.pdf
JoelVilloso1
 
BANDHA (BANDAGES) PPT.pptx ayurveda shalya tantra
rakhan78619
 
Soil and agriculture microbiology .pptx
Keerthana Ramesh
 
How to Configure Access Rights of Manufacturing Orders in Odoo 18 Manufacturing
Celine George
 
'' IMPORTANCE OF EXCLUSIVE BREAST FEEDING ''
SHAHEEN SHAIKH
 
Health Planning in india - Unit 03 - CHN 2 - GNM 3RD YEAR.ppsx
Priyanshu Anand
 
Unit 2 COMMERCIAL BANKING, Corporate banking.pptx
AnubalaSuresh1
 
How to Manage Promotions in Odoo 18 Sales
Celine George
 
Quarter1-English3-W4-Identifying Elements of the Story
FLORRACHELSANTOS
 

How to develope plugin in wordpress: 6 simple steps.

  • 1. How to develop a plugin in wordpress With 6 easy simplest steps by Jay Bharat 1
  • 2. Step1 • Close your eyes for 1 minute for take relax. • Open your eyes 2
  • 3. Step2 • Go to folder: • wordpress/wp-content/plugins/ • Create a folder with any meaningful name. • Create a file with any meaningful name under newly creted folder as above. • Example: /Users/jay/9844542127/im-mac- desktop/php-mamp-wamp/wordpress/wp- content/plugins/jayplugin 3
  • 4. Step3 • Here I have created a file (jayplugin1.php) inside my jayplugin folder • See the screen shot in next page 4
  • 5. 5
  • 6. Step4: write below code in newly created file (here i.e: jayplugin1.php) • <? • /* • Plugin Name: Jay WP Plugin Demo • Plugin URI: http://www.bharatbaba.com • Description: Tutorial for how to develope a plugin in wordpress • Author: Jay Bharat/9844542127/[email protected] • Version: 1.0/26-may-2015 • Author URI: http://www.bharatbaba.com • */ • function limited_character_post( $limit ) { • $content = explode( ' ', get_the_content(), $limit ); • • if ( count( $content ) >= $limit ) { • array_pop( $content ); • $content = implode(" ",$content).'...'; • } else { • $content = implode(" ",$content); • } • • $content = preg_replace('/[.+]/','', $content); • $content = apply_filters('the_content', $content); • return $content; • } • //code closed 6
  • 7. • Screen shot for same as reference: 7
  • 8. Step5 • Login as admin in wordpress • Go to plugins section in admin panel • You can see your plugin is appearing here with name (as example here: Jay WP Plugin Demo) • See the screen shot on above page • Just click on activate 8
  • 9. 9
  • 10. • I have activated it, see the screen shot below. 10
  • 11. Step6 • This is the time to use your plugin for output. • Go to index.php of your activated theme. • Add this line: • echo limited_character_post (10); // this line will display limited 10 chars long • For example see the code screen shot and output screen shot on next page. 11
  • 12. • Code for display the code: echo limited_character_post(10); // this line will display limited 10 chars long 12
  • 13. • Output as: Welcome to WordPress. This is your first post. Edit… • This output coming from this function: limited_character_post 13
  • 14. Note • I am using : WordPress 4.2.2 helps you communicate and share, globally. • Above version • But above tutorial will work almost all version. • My current activated theme is: Twenty Fifteen, but not matter it will work for all designed theme. • Thanks for attend. 14