PHP Classes

File: manual.txt

Recommend this page to a friend!
  Classes of Dave Smith   PHP Plugin System   manual.txt   Download  
File: manual.txt
Role: Documentation
Content type: text/plain
Description: Documentation
Class: PHP Plugin System
Extend functionality using plugin classes
Author: By
Last change:
Date: 8 years ago
Size: 2,476 bytes


Class file image Download
Class: plugin Version: 1.0 4/19/2015 Copyright 2015 Wagon Trader, All Rights Reserved Description: This class will allow you to develop plugins, expanding the functionality of your applications by triggering method calls across all supplied plugins, called observer classes. Properties of the observer class become available immediately to your application simply by dropping the observer into the plugins folder. Unlike the standard observer model, the observer class does not have to be explicitly set, it is instantiated because it exists. Files: plugin.class.php - Main class example.php - Example usage script /plugins folder - Sample observer class files Installation: Upload files to a web accessible location on your server (eg. public_html) Configuration: The class if configured to work with most server configurations. You can change the following settings in the class should you need to... $rootPath - Leave blank to use the server specified root path to your document root or set the full path yourself. $scriptFolder - Leave blank if this script is installed at the document root or specify the folder where this script is installed. $pluginFolder - Specify the folder off of the script folder where the observer classes are installed. By default this will be a folder named 'pluginclass'. Usage: The included example.php file includes examples on instantiating the class and basic operation instructions. You must follow these naming conventions for observer classes: 1) Observer class file names must have all characters preceding the first decimal point be unique to each file. 2) Class name must match all characters preceding the first decimal point of the file name. This script uses the characters preceding the first decimal point in the file name to track and instantiate the classes. A file named 'member.class.php' must have the class named 'member' and no other file can be named with 'member' preceding the first decimal point. For example, files named: member.class.php and forum.php is okay since one class will be 'member' and the other will be 'forum'. member.class.php and member.php will not work since each class will be 'member'. This script is simply the back end to manage the plug and play scripts you create. You will need to write your own main application and plugin applications, as detailed as you need, to take advantage of this classes features.