PHP Plugin System

kesne

New Member
Messages
47
Reaction score
0
Points
0
Hey everyone, does anyone know how to go about making a PHP Plugin system?

Thanks in advance,
Jordan
 

kesne

New Member
Messages
47
Reaction score
0
Points
0
I know how to use google. ;)

Most of those links are not what I am looking for or contian dead links.
 

garrettroyce

Community Support
Community Support
Messages
5,611
Reaction score
249
Points
63
I know how to use google. ;)

Most of those links are not what I am looking for or contian dead links.

I'm not sure what you're looking for then, can you be more specific?
 

kesne

New Member
Messages
47
Reaction score
0
Points
0
A simple plugin system that allows plugin authors maximum options and that allows multiple plugins.

A plugin system similar to wordpress.


Thanks,
Jordan
 

garrettroyce

Community Support
Community Support
Messages
5,611
Reaction score
249
Points
63
I guess, to be very general, you need to separate what you are doing with how you are doing it.

For example, for a blog, you know you are going to display a title and some content. This will be the same no matter what. Then you have a plugin that chooses how to display it.

Code:
some pseudo code

#every blog must have a title and content
$title = get_title();
$content = get_content();

#how this title and content is displayed or modified is up to the plugin
$plugin = get_plugin();
$plugin->title = $title;
$plugin->content = $content;
$plugin->make_blog_post();

Since you are creating everything from scratch, I couldn't really tell you how to do it, other than something that makes sense to you.

I usually find some open source code and pick it apart to learn how others do it. Keep in mind that wordpress has hundreds of people contributing code and plugins, and for someone to do all of the same work by him/herself would take a very long time.
 
Last edited:
Top