Joomla CMS  3.10.11 (avec JPlatform 13.1 inclus)
Documentation des API du CMS Joomla en version 3.10.11 et du framework Joomla Platform intégré
Référence de la classe PlgContentJoomla
+ Graphe d'héritage de PlgContentJoomla:

Fonctions membres publiques

 onContentAfterSave ($context, $article, $isNew)
 
 onContentBeforeDelete ($context, $data)
 
 onContentChangeState ($context, $pks, $value)
 
 onContentBeforeSave ($context, $table, $isNew)
 

Fonctions membres privées

 _countItemsInCategory ($table, $catid)
 
 _countItemsInChildren ($table, $catid, $data)
 

Description détaillée

Example Content Plugin

Depuis
1.6

Documentation des fonctions membres

◆ _countItemsInCategory()

_countItemsInCategory (   $table,
  $catid 
)
private

Get count of items in a category

Paramètres
string$tabletable name of component table (column is catid)
integer$catidid of the category to check
Renvoie
mixed count of items found or false if db error
Depuis
1.6

Références $count, $db, $query, et JError\raiseWarning().

◆ _countItemsInChildren()

_countItemsInChildren (   $table,
  $catid,
  $data 
)
private

Get count of items in a category's child categories

Paramètres
string$tabletable name of component table (column is catid)
integer$catidid of the category to check
object$dataThe data relating to the content that was deleted.
Renvoie
mixed count of items found or false if db error
Depuis
1.6

Références $count, $data, $db, $query, et JError\raiseWarning().

◆ onContentAfterSave()

onContentAfterSave (   $context,
  $article,
  $isNew 
)

Example after save content method Article is passed by reference, but after the save, so no changes will be saved. Method is called right after the content is saved

Paramètres
string$contextThe context of the content passed to the plugin (added in 1.6)
object$articleA JTableContent object
boolean$isNewIf the content is just about to be created
Renvoie
boolean true if function not enabled, is in frontend or is new. Else true or false depending on success of save function.
Depuis
1.6

Références $article, $context, $db, $lang, $message, $query, $user, $users, et JPATH_ADMINISTRATOR.

◆ onContentBeforeDelete()

onContentBeforeDelete (   $context,
  $data 
)

Don't allow categories to be deleted if they contain items or subcategories with items

Paramètres
string$contextThe context for the content passed to the plugin.
object$dataThe data relating to the content that was deleted.
Renvoie
boolean
Depuis
1.6

Références $context, $count, $data, $extension, elseif, et JError\raiseWarning().

◆ onContentBeforeSave()

onContentBeforeSave (   $context,
  $table,
  $isNew 
)

The save event.

Paramètres
string$contextThe context
object$tableThe item
boolean$isNewIs new item
Renvoie
void
Depuis
3.9.12

Références $context, et $params.

◆ onContentChangeState()

onContentChangeState (   $context,
  $pks,
  $value 
)

Change the state in core_content if the state in a table is changed

Paramètres
string$contextThe context for the content passed to the plugin.
array$pksA list of primary key ids of the content that has changed state.
integer$valueThe value of the state that the content has been changed to.
Renvoie
boolean
Depuis
3.1

Références $context, $db, $query, et $value.


La documentation de cette classe a été générée à partir du fichier suivant :