XOOPS  2.6.0
Xmf\Module\Admin Class Reference

Public Member Functions

 addConfigBoxLine ($value= '', $type= 'default')
 
 addInfoBox ($title, $type= 'default', $extra= '')
 
 addInfoBoxLine ($text= '', $type= 'default', $color= 'inherit')
 
 addItemButton ($title, $link, $icon= 'add', $extra= '')
 
 displayAbout ($logo_xoops=true)
 
 displayButton ($position=null, $delimiter=" ")
 
 displayIndex ()
 
 displayInfoBox ()
 
 displayNavigation ($menu= '')
 
 renderAbout ($logo_xoops=true)
 
 renderButton ($position=null, $delimiter=" ")
 
 renderIndex ()
 
 renderInfoBox ()
 

Static Public Member Functions

static addConfigAccept ($value= '')
 
static addConfigError ($value= '')
 
static checkModuleVersion ($moddir, $minversion)
 
static getInstance ()
 
static iconUrl ($name= '', $size= '32')
 
static is26 ()
 
static menuIconPath ($image)
 
static setPaypal ($paypal= '')
 

Private Member Functions

 __construct ()
 

Private Attributes

 $lastInfoBoxTitle = null
 
 $version26 = null
 

Static Private Attributes

static $ModuleAdmin = null
 
static $paypal = ''
 

Detailed Description

Definition at line 30 of file Admin.php.

Constructor & Destructor Documentation

Xmf\Module\Admin::__construct ( )
private

Constructor

Definition at line 46 of file Admin.php.

Member Function Documentation

static Xmf\Module\Admin::addConfigAccept (   $value = '')
static

Add accept (OK) message to config box

Parameters
string$valuethe OK message
Returns
bool

Definition at line 342 of file Admin.php.

References $path, $type, and XoopsBaseConfig\get().

Here is the call graph for this function:

Xmf\Module\Admin::addConfigBoxLine (   $value = '',
  $type = 'default' 
)

Add config line

Parameters
string$valuemessage to include in config box
string$typetype of line to add
Returns
bool

Definition at line 134 of file Admin.php.

References $type.

static Xmf\Module\Admin::addConfigError (   $value = '')
static

Add error to config box

Parameters
string$valuethe error message
Returns
bool

Definition at line 317 of file Admin.php.

References $path, $type, and XoopsBaseConfig\get().

Here is the call graph for this function:

Xmf\Module\Admin::addInfoBox (   $title,
  $type = 'default',
  $extra = '' 
)

Add Info box

Parameters
string$titleinfo box title
string$typefor compatibility only
string$extrafor compatibility only
Returns
bool

Definition at line 148 of file Admin.php.

Xmf\Module\Admin::addInfoBoxLine (   $text = '',
  $type = 'default',
  $color = 'inherit' 
)

Add line to the info box

Parameters
string$texttext to add to info box
string$typetype of infobox line
string$colorcolor for infobox line
Returns
bool

Definition at line 164 of file Admin.php.

References $text, and $type.

Xmf\Module\Admin::addItemButton (   $title,
  $link,
  $icon = 'add',
  $extra = '' 
)

Add Item button

Parameters
string$titletitle of button
string$linklink for button
string$iconicon for button
string$extraextra
Returns
bool

Definition at line 185 of file Admin.php.

References $link.

static Xmf\Module\Admin::checkModuleVersion (   $moddir,
  $minversion 
)
static

Check for installed module and version and do addConfigBoxLine()

Parameters
string$moddir- module directory name
integer$minversion- minimum acceptable module version (100 = V1.00)
Returns
bool true if requested version of the module is available

Definition at line 408 of file Admin.php.

References $helper, _AM_XMF_DEMOMVC_MODULE_NOTFOUND, _AM_XMF_DEMOMVC_MODULE_VERSION, Xmf\Module\Helper\getHelper(), and Xmf\Language\load().

Here is the call graph for this function:

Xmf\Module\Admin::displayAbout (   $logo_xoops = true)

Display about page

Parameters
bool$logo_xoopsdisplay XOOPS logo
Returns
void

Definition at line 303 of file Admin.php.

References Xmf\Module\Admin\renderAbout().

Here is the call graph for this function:

Xmf\Module\Admin::displayButton (   $position = null,
  $delimiter = " " 
)

Display all item buttons

Parameters
string$positionbutton position (left, right)
string$delimiterdelimiter between buttons
Returns
void

Definition at line 215 of file Admin.php.

References Xmf\Module\Admin\renderButton().

Here is the call graph for this function:

Xmf\Module\Admin::displayIndex ( )

Display index page for admin

Returns
void

Definition at line 255 of file Admin.php.

References Xmf\Module\Admin\renderIndex().

Here is the call graph for this function:

Xmf\Module\Admin::displayInfoBox ( )

Display InfoBox

Returns
void

Definition at line 235 of file Admin.php.

References Xmf\Module\Admin\renderInfoBox().

Here is the call graph for this function:

Xmf\Module\Admin::displayNavigation (   $menu = '')

Display the navigation menu

Parameters
string$menumenu key (script name, i.e. index.php)
Returns
void

Definition at line 267 of file Admin.php.

References $menu.

static Xmf\Module\Admin::getInstance ( )
static

Retrieve a module admin instance

If we are on 2.6 this will be the a XoopsModuleAdmin instance. Older systems with the Frameworks based admin class will get an instance of this class which provides compatible methods built from the old Frameworks version.

Always use this to get the ModuleAdmin instance if you use anything (even the static methods) of this class.

Returns
object a ModuleAdmin instance.
Since
1.0

Definition at line 66 of file Admin.php.

References XoopsBaseConfig\get(), and Xmf\Loader\loadFile().

Here is the call graph for this function:

static Xmf\Module\Admin::iconUrl (   $name = '',
  $size = '32' 
)
static

Get an appropriate URL for system provided icons.

Things which were in Frameworks in 2.5 are in media in 2.6, making it harder to use and rely on the standard icons.

not part of 2.6, just a transition assist

Parameters
string$namethe image name to provide URL for, or blank to just get the URL path.
string$sizethe icon size (directory). Valid values are 16, 32 or /. A '/' slash will simply set the path to the icon directory and append $image.
Returns
string true if we are in a 2.6 environment

Definition at line 376 of file Admin.php.

References $name, $path, and XoopsBaseConfig\get().

Here is the call graph for this function:

static Xmf\Module\Admin::is26 ( )
static

Are we in a 2.6 environment?

just to help with other admin things than ModuleAdmin

not part of 2.6 module admin

Returns
bool true if we are in a 2.6 environment

Definition at line 99 of file Admin.php.

static Xmf\Module\Admin::menuIconPath (   $image)
static

Get an appropriate imagePath for menu.php use.

just to help with other admin things than ModuleAdmin

not part of 2.6 module admin

Parameters
string$imageicon name to prepend with path
Returns
string true if we are in a 2.6 environment

Definition at line 115 of file Admin.php.

References $image, and $path.

Xmf\Module\Admin::renderAbout (   $logo_xoops = true)

Render about page

Parameters
bool$logo_xoopsdisplay XOOPS logo
Returns
bool|mixed|string

Definition at line 279 of file Admin.php.

Referenced by Xmf\Module\Admin\displayAbout().

Here is the caller graph for this function:

Xmf\Module\Admin::renderButton (   $position = null,
  $delimiter = " " 
)

Render all items buttons

Parameters
string$positionbutton position (left, right)
string$delimiterdelimiter between buttons
Returns
string

Definition at line 198 of file Admin.php.

Referenced by Xmf\Module\Admin\displayButton().

Here is the caller graph for this function:

Xmf\Module\Admin::renderIndex ( )

Render index page for admin

Returns
string HTML rendered info box

Definition at line 245 of file Admin.php.

Referenced by Xmf\Module\Admin\displayIndex().

Here is the caller graph for this function:

Xmf\Module\Admin::renderInfoBox ( )

Render InfoBox

Returns
string HTML rendered info box

Definition at line 225 of file Admin.php.

Referenced by Xmf\Module\Admin\displayInfoBox().

Here is the caller graph for this function:

static Xmf\Module\Admin::setPaypal (   $paypal = '')
static

set paypal for 2.5 renderAbout

Parameters
string$paypalPayPal identifier for donate button
Returns
void

Definition at line 291 of file Admin.php.

References Xmf\Module\Admin\$paypal.

Member Data Documentation

Xmf\Module\Admin::$lastInfoBoxTitle = null
private

Definition at line 40 of file Admin.php.

Xmf\Module\Admin::$ModuleAdmin = null
staticprivate

Definition at line 38 of file Admin.php.

Xmf\Module\Admin::$paypal = ''
staticprivate

Definition at line 41 of file Admin.php.

Referenced by Xmf\Module\Admin\setPaypal().

Xmf\Module\Admin::$version26 = null
private

Definition at line 39 of file Admin.php.


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