WPDK  1.5.0
WordPress Development Kit
 All Data Structures Files Functions Variables Pages
WPDKPlugin Class Reference
Inheritance diagram for WPDKPlugin:
WPDKWordPressPlugin

Public Member Functions

 __construct ($file=null)
 Construct. More...
 
 active ()
 
 deactive ()
 
 uninstall ()
 
 readMetadata ($aWPXHeaders)
 

Data Fields

 $active = false
 Active. More...
 
 $author = ''
 Author. More...
 
 $authorName = ''
 Author. More...
 
 $authorURI = ''
 Author URI. More...
 
 $description = ''
 Description. More...
 
 $file = ''
 Path file. More...
 
 $icon = ''
 Icon. More...
 
 $id = ''
 ID. More...
 
 $name = ''
 Plugin name. More...
 
 $network = ''
 Network. More...
 
 $pluginURI = ''
 Plugin URI. More...
 
 $textDomain = ''
 Plugin Text Domain. More...
 
 $textDomainPath = ''
 Text domain Plugin url. More...
 
 $title = ''
 Title. More...
 
 $version = ''
 Version. More...
 

Detailed Description

Wrap for generic plugin object. This class is used to manage any plugin installed (enabled or disabled). This class is very different from WPDKWordPressPlugin because can describe any WordPress Plugin. Also, it is the logical model of any plugin.

Author
=undo= info@.nosp@m.wpxt.nosp@m.re.me
Date
2013-11-15
Version
1.0.0

Definition at line 592 of file wpdk-wordpress-plugin.php.

Constructor & Destructor Documentation

__construct (   $file = null)

Construct.

Create an instance of WPDKPlugin class

Parameters
null$fileOptional. Usually constant FILE
Returns
WPDKPlugin

Definition at line 740 of file wpdk-wordpress-plugin.php.

Member Function Documentation

active ( )

Definition at line 771 of file wpdk-wordpress-plugin.php.

deactive ( )

Definition at line 774 of file wpdk-wordpress-plugin.php.

readMetadata (   $aWPXHeaders)

Retrieve metadata from the main file of plugin.

Searches for metadata in the first 8kiB of a file, such as a plugin or theme. Each piece of metadata must be on its own line. Fields can not span multiple lines, the value will get cut at the end of the first line.

If the file data is not within that first 8kiB, then the author should correct their plugin file and move the data headers to the top.

Since
1.0.0.b4
Deprecated:
since 1.1.4 - Use get_file_data()
Parameters
array$aWPXHeadersList of metadata to get, in the format `array( 'Header Name' ==> '', ... )`
Returns
array|boolean The array with all metadata got from main file of plugin, or FALSE in case of an error.

Definition at line 797 of file wpdk-wordpress-plugin.php.

uninstall ( )

Definition at line 777 of file wpdk-wordpress-plugin.php.

Field Documentation

bool $active = false

Active.

The Active flag

Definition at line 601 of file wpdk-wordpress-plugin.php.

string $author = ''

Author.

The Author get from get_plugin_data(), 'Author' parameter

Definition at line 610 of file wpdk-wordpress-plugin.php.

string $authorName = ''

Author.

The Author name from get_plugin_data(), 'AuthorName' parameter

Definition at line 619 of file wpdk-wordpress-plugin.php.

string $authorURI = ''

Author URI.

The Author URI from get_plugin_data(), 'AuthorURI' parameter

Definition at line 628 of file wpdk-wordpress-plugin.php.

string $description = ''

Description.

Long description of plugin

Definition at line 637 of file wpdk-wordpress-plugin.php.

string $file = ''

Path file.

Usually FILE

Since
1.0.0.b4

Definition at line 648 of file wpdk-wordpress-plugin.php.

string $icon = ''

Icon.

The standard WPDK 64x64 icon path

Definition at line 657 of file wpdk-wordpress-plugin.php.

string $id = ''

ID.

This is the ID of plugin. This property is 'folder/main file.php'

Definition at line 666 of file wpdk-wordpress-plugin.php.

string $name = ''

Plugin name.

Name of plugin

Definition at line 675 of file wpdk-wordpress-plugin.php.

string $network = ''

Network.

The Network activation get from get_plugin_data(), 'Network' parameter

Definition at line 684 of file wpdk-wordpress-plugin.php.

string $pluginURI = ''

Plugin URI.

Address of plugin repository

Definition at line 693 of file wpdk-wordpress-plugin.php.

string $textDomain = ''

Plugin Text Domain.

The plugin text domain get from get_plugin_data(), 'Text Domain' parameter

Definition at line 702 of file wpdk-wordpress-plugin.php.

string $textDomainPath = ''

Text domain Plugin url.

The complete Text domain Plugin url get from get_plugin_data(), 'Domain Path' parameter

Definition at line 711 of file wpdk-wordpress-plugin.php.

string $title = ''

Title.

The plugin title. This is the same as name

Definition at line 720 of file wpdk-wordpress-plugin.php.

string $version = ''

Version.

Plugin version

Definition at line 729 of file wpdk-wordpress-plugin.php.


The documentation for this class was generated from the following file: