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é
Tout Structures de données Espaces de nommage Fichiers Fonctions Variables Pages
Référence de la classe Pagination

Fonctions membres publiques

 __construct ($total, $limitstart, $limit, $prefix='', CMSApplication $app=null)
 
 setAdditionalUrlParam ($key, $value)
 
 getAdditionalUrlParam ($key)
 
 getRowOffset ($index)
 
 getData ()
 
 getPagesCounter ()
 
 getResultsCounter ()
 
 getPagesLinks ()
 
 getPaginationLinks ($layoutId='joomla.pagination.links', $options=array())
 
 getPaginationPages ()
 
 getListFooter ()
 
 getLimitBox ()
 
 orderUpIcon ($i, $condition=true, $task='orderup', $alt='JLIB_HTML_MOVE_UP', $enabled=true, $checkbox='cb')
 
 orderDownIcon ($i, $n, $condition=true, $task='orderdown', $alt='JLIB_HTML_MOVE_DOWN', $enabled=true, $checkbox='cb')
 
 set ($property, $value=null)
 
 get ($property, $default=null)
 

Champs de données

 $limitstart = null
 
 $limit = null
 
 $total = null
 
 $prefix = null
 
 $pagesStart
 
 $pagesStop
 
 $pagesCurrent
 
 $pagesTotal
 
 $hideEmptyLimitstart = false
 

Fonctions membres protégées

 _list_footer ($list)
 
 _list_render ($list)
 
 _item_active (PaginationObject $item)
 
 _item_inactive (PaginationObject $item)
 
 _buildDataObject ()
 

Attributs protégés

 $viewall = false
 
 $additionalUrlParams = array()
 
 $app = null
 
 $data
 

Description détaillée

Pagination Class. Provides a common interface for content pagination for the Joomla! CMS.

Depuis
1.5

Documentation des constructeurs et destructeur

◆ __construct()

__construct (   $total,
  $limitstart,
  $limit,
  $prefix = '',
CMSApplication  $app = null 
)

Constructor.

Paramètres
integer$totalThe total number of items.
integer$limitstartThe offset of the item to start at.
integer$limitThe number of items to display per page.
string$prefixThe prefix used for request variables.
CMSApplication$appThe application object
Depuis
1.5

Références $app, $limit, $pagesTotal, $prefix, $total, et prefix.

Documentation des fonctions membres

◆ _buildDataObject()

_buildDataObject ( )
protected

Create and return the pagination data object.

Renvoie
Pagination data object.
Depuis
1.5

Références $data, $i, $key, $limit, $offset, $params, $value, et prefix.

◆ _item_active()

_item_active ( PaginationObject  $item)
protected

Method to create an active pagination link to the item

Paramètres
PaginationObject$itemThe object with which to make an active link.
Renvoie
string HTML link
Depuis
1.5
Note
As of 4.0 this method will proxy to ‘::render('joomla.pagination.link’, ['data' => $item, 'active' => true])`

Références $class, $item, $title, et prefix.

◆ _item_inactive()

_item_inactive ( PaginationObject  $item)
protected

Method to create an inactive pagination string

Paramètres
PaginationObject$itemThe item to be processed
Renvoie
string
Depuis
1.5
Note
As of 4.0 this method will proxy to ‘::render('joomla.pagination.link’, ['data' => $item, 'active' => false])`

Références $item.

◆ _list_footer()

_list_footer (   $list)
protected

Create the HTML for a list footer

Paramètres
array$listPagination list data structure.
Renvoie
string HTML for a list footer
Depuis
1.5

Références $html, et $list.

◆ _list_render()

_list_render (   $list)
protected

Create the html for a list footer

Paramètres
array$listPagination list data structure.
Renvoie
string HTML for a list start, previous, next,end
Depuis
1.5

Références $list.

◆ get()

get (   $property,
  $default = null 
)

Returns a property of the object or the default value if the property is not set.

Paramètres
string$propertyThe name of the property.
mixed$defaultThe default value.
Renvoie
mixed The value of the property.
Depuis
3.0
Obsolète:
4.0 Access the properties directly.

Références $default.

◆ getAdditionalUrlParam()

getAdditionalUrlParam (   $key)

Method to get an additional URL parameter (if it exists) to be added to all pagination class generated links.

Paramètres
string$keyThe name of the URL parameter for which to get the value.
Renvoie
mixed The value if it exists or null if it does not.
Depuis
1.6

Références $key, et null.

◆ getData()

getData ( )

Return the pagination data object, only creating it if it doesn't already exist.

Renvoie
Pagination data object.
Depuis
1.5

Références $data.

◆ getLimitBox()

getLimitBox ( )

Creates a dropdown box for selecting how many records to show per page.

Renvoie
string The HTML for the limit # input box.
Depuis
1.5

Références $html, $i, $limit, $selected, et prefix.

◆ getListFooter()

getListFooter ( )

Return the pagination footer.

Renvoie
string Pagination footer.
Depuis
1.5

Références $list, JPATH_THEMES, pagination_list_footer(), et prefix.

◆ getPagesCounter()

getPagesCounter ( )

Create and return the pagination pages counter string, ie. Page 2 of 4.

Renvoie
string Pagination pages counter string.
Depuis
1.5

Références $html, et null.

◆ getPagesLinks()

getPagesLinks ( )

Create and return the pagination page list string, ie. Previous, Next, 1 2 3 ... x.

Renvoie
string Pagination page list string.
Depuis
1.5

Références $data, $i, $list, $prefix, JPATH_THEMES, null, pagination_item_active(), pagination_item_inactive(), et pagination_list_render().

◆ getPaginationLinks()

getPaginationLinks (   $layoutId = 'joomla.pagination.links',
  $options = array() 
)

Get the pagination links

Paramètres
string$layoutIdLayout to render the links
array$optionsOptional array with settings for the layout
Renvoie
string Pagination links.
Depuis
3.3

Références $list, $options, null, et prefix.

◆ getPaginationPages()

getPaginationPages ( )

Create and return the pagination pages list, ie. Previous, Next, 1 2 3 ... x.

Renvoie
array Pagination pages list.
Depuis
3.3

Références $data, $i, $list, et null.

◆ getResultsCounter()

getResultsCounter ( )

Create and return the pagination result set counter string, e.g. Results 1-10 of 42

Renvoie
string Pagination result set counter string.
Depuis
1.5

Références $html, $limit, $total, et null.

◆ getRowOffset()

getRowOffset (   $index)

Return the rationalised offset for a row with a given index.

Paramètres
integer$indexThe row index
Renvoie
integer Rationalised offset for a row with a given index.
Depuis
1.5

◆ orderDownIcon()

orderDownIcon (   $i,
  $n,
  $condition = true,
  $task = 'orderdown',
  $alt = 'JLIB_HTML_MOVE_DOWN',
  $enabled = true,
  $checkbox = 'cb' 
)

Return the icon to move an item DOWN.

Paramètres
integer$iThe row index.
integer$nThe number of items in the list.
boolean$conditionTrue to show the icon.
string$taskThe task to fire.
string$altThe image alternative text string.
boolean$enabledAn optional setting for access control on the action.
string$checkboxAn optional prefix for checkboxes.
Renvoie
string Either the icon to move an item down or a space.
Depuis
1.5

Références $alt, $condition, $enabled, $i, et $task.

◆ orderUpIcon()

orderUpIcon (   $i,
  $condition = true,
  $task = 'orderup',
  $alt = 'JLIB_HTML_MOVE_UP',
  $enabled = true,
  $checkbox = 'cb' 
)

Return the icon to move an item UP.

Paramètres
integer$iThe row index.
boolean$conditionTrue to show the icon.
string$taskThe task to fire.
string$altThe image alternative text string.
boolean$enabledAn optional setting for access control on the action.
string$checkboxAn optional prefix for checkboxes.
Renvoie
string Either the icon to move an item up or a space.
Depuis
1.5

Références $alt, $condition, $enabled, $i, et $task.

◆ set()

set (   $property,
  $value = null 
)

Modifies a property of the object, creating it if it does not already exist.

Paramètres
string$propertyThe name of the property.
mixed$valueThe value of the property to set.
Renvoie
void
Depuis
3.0
Obsolète:
4.0 Access the properties directly.

Références $value.

◆ setAdditionalUrlParam()

setAdditionalUrlParam (   $key,
  $value 
)

Method to set an additional URL parameter to be added to all pagination class generated links.

Paramètres
string$keyThe name of the URL parameter for which to set a value.
mixed$valueThe value to set for the URL parameter.
Renvoie
mixed The old value for the parameter.
Depuis
1.6

Références $key, $value, et null.

Documentation des champs

◆ $additionalUrlParams

$additionalUrlParams = array()
protected

◆ $app

$app = null
protected

◆ $data

$data
protected

◆ $hideEmptyLimitstart

$hideEmptyLimitstart = false

◆ $limit

$limit = null

◆ $limitstart

$limitstart = null

◆ $pagesCurrent

$pagesCurrent

◆ $pagesStart

$pagesStart

◆ $pagesStop

$pagesStop

◆ $pagesTotal

$pagesTotal

◆ $prefix

◆ $total

$total = null

◆ $viewall

$viewall = false
protected

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