OPEN SOURCE SOCIAL NETWORK 6.6
Loading...
Searching...
No Matches
OssnComponents Class Reference
Inheritance diagram for OssnComponents:
OssnDatabase OssnBase OssnSession

Public Member Functions

 getComponentsDir ()
 
 total ()
 
 getComponents ()
 
 upload ()
 
 newCom ($com)
 
 loadComs ()
 
 getActive ($ids_only=false)
 
 isOld ($element)
 
 inUseBy ($comId)
 
 isActive ($id='')
 
 enable ($com)
 
 delete ($com)
 
 requiredComponents ()
 
 DISABLE ($com=null)
 
 bundledComponents ()
 
 setSettings ($component, array $vars=array())
 
 getSettings ($component)
 
 getComSettings ($component)
 
 getbyName ($name)
 
 savePref (string $com_id)
 
 restorePref (string $com_id)
 
- Public Member Functions inherited from OssnDatabase
 __construct ()
 
 Connect ()
 
 insert ($params)
 
 statement ($query)
 
 execute ($values=array())
 
 update ($params=array())
 
 select ($params, $multi='')
 
 fetch ($data=false)
 
 delete ($params)
 
 getLastEntry ()
 
 constructWheres (array $array, $operator="AND")
 
 generateLimit ($data_limit=false, $page_limit=false, $offset=false)
 
 clearVars ()
 
 __destruct ()
 
- Public Member Functions inherited from OssnBase
 getGUID ()
 
 getID ()
 
 getParam ($param)
 
 isParam ($param)
 
 __call ($method, $args)
 

Static Public Member Functions

static getCom ($name)
 
static checkRequirments ($element)
 
- Static Public Member Functions inherited from OssnSession
static start ()
 
static assign ($name='', $value='')
 
static unassign ($name='')
 
static isSession ($name='')
 
static getSession ($name='')
 

Member Function Documentation

◆ bundledComponents()

bundledComponents ( )

Bundled components

Returns
array

◆ checkRequirments()

static checkRequirments (   $element)
static

Check component requirments

Parameters
string$elementA valid component xml file
Returns
false|array

◆ delete()

delete (   $com)

Delete component

Returns
boolean

Reimplemented from OssnDatabase.

◆ DISABLE()

DISABLE (   $com = null)

Disable component

Returns
boolean

◆ enable()

enable (   $com)

Enable Component

Returns
boolean

◆ getActive()

getActive (   $ids_only = false)

Get active components

Returns
active components;

◆ getbyName()

getbyName (   $name)

Get component

Note
This id is not a package id
Returns
integer|false;

◆ getCom()

static getCom (   $name)
static

Get component details

@params string $name Component id;

Returns
false|object

◆ getComponents()

getComponents ( )

Get components list

Returns
array

◆ getComponentsDir()

getComponentsDir ( )

Get components from compnents directory

Returns
array

◆ getComSettings()

getComSettings (   $component)

Get Component Settings

@params string $component Component id

Note
This method is deprecated and will be removed in Ossn v4.0
Returns
false|array;

◆ getSettings()

getSettings (   $component)

Get Component Settings

Parameters
string$componentComponent id
Returns
false|array;

◆ inUseBy()

inUseBy (   $comId)

Check if $comId is defined as required in XML of other active component

@params string $comId Component id;

Returns
array

◆ isActive()

isActive (   $id = '')

Check if component is active or not

Returns
boolean

◆ isOld()

isOld (   $element)

Check if component is older than 3.x

Parameters
string$elementComponent xml string.
Returns
boolean

◆ loadComs()

loadComs ( )

Load all active components

Returns
false|null startup files;

◆ newCom()

newCom (   $com)

Insert a new component to system

Returns
boolean

◆ requiredComponents()

requiredComponents ( )

Required Components

Admin can't disable required components;

Returns
array

◆ restorePref()

restorePref ( string  $com_id)

Restore preference

Parameters
string$com_idComponent ID
Returns
boolean

◆ savePref()

savePref ( string  $com_id)

Keep preference on next upload

Parameters
string$com_idComponent ID
Returns
boolean

◆ setSettings()

setSettings (   $component,
array  $vars = array() 
)

Set component settings

setSettings should have array() to accept values #434

Parameters
string$componentComponent id
arrayvars Setting (two-dem array)
Returns
boolean

◆ total()

total ( )

Count total components

Returns
integer

◆ upload()

upload ( )

Upload component

Requires component package file,

Returns
boolean

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