Methods summary
public
|
|
public static
|
|
public
|
|
public
array
|
#
getPages( boolean $published = NULL, boolean $toplevel = false, integer $number = NULL, string $sorttype = NULL, string $sortdirection = NULL )
Gets all pages or published ones.
Gets all pages or published ones.
NOTE: Since this function only returns titlelinks for use with the object model it does not exclude pages that are password protected
Parameters
- $published
- TRUE for published or FALSE for all pages including un-published
- $toplevel
- TRUE for only the toplevel pages
- $number
- number of pages to get (NULL by default for all)
- $sorttype
- NULL for the standard order as sorted on the backend, "title", "date", "id", "popular", "mostrated", "toprated", "random"
- $sortdirection
- false for ascenting, true for descending
Returns
array
|
public
array
|
#
getNotViewablePages( )
Returns a list of Zenpage page IDs that the current viewer is not allowed to see
Helper function to be used with getAllTagsUnique() and getAllTagsCount()
Note if the Zenpage plugin is not enabled but items exists this returns no IDs so you need an extra check afterwards!
Returns a list of Zenpage page IDs that the current viewer is not allowed to see
Helper function to be used with getAllTagsUnique() and getAllTagsCount()
Note if the Zenpage plugin is not enabled but items exists this returns no IDs so you need an extra check afterwards!
Returns
array
|
public
array
|
#
getArticles( integer $articles_per_page = 0, string $published = NULL, boolean $ignorepagination = false, string $sortorder = NULL, boolean $sortdirection = NULL, boolean $sticky = NULL, $category = NULL )
Gets all news articles titlelink.
Gets all news articles titlelink.
NOTE: Since this function only returns titlelinks for use with the object model it does not exclude articles that are password protected via a category
Parameters
- $articles_per_page
- The number of articles to get
- $published
"published" for an published articles,
"unpublished" for an unpublised articles,
"published-unpublished" for published articles only from an unpublished category,
"sticky" for sticky articles (published or not!) for admin page use only,
"all" for all articles
- $ignorepagination
- Since also used for the news loop this function automatically paginates the results if the "page" GET variable is set. To avoid this behaviour if using it directly to get articles set this TRUE (default FALSE)
- $sortorder
"date" (default), "title", "id, "popular", "mostrated", "toprated", "random"
This parameter is not used for date archives
- $sortdirection
- TRUE for descending, FALSE for ascending. Note: This parameter is not used for date archives
- $sticky
- set to true to place "sticky" articles at the front of the list.
- $category
Returns
array
|
public
array
|
#
getNotViewableNews( )
Returns a list of Zenpage news article IDs that the current viewer is not allowed to see
Helper function to be used with getAllTagsUnique() and getAllTagsCount() or db queries only
Note if the Zenpage plugin is not enabled but items exists this returns no IDs so you need an extra check afterwards!
Returns a list of Zenpage news article IDs that the current viewer is not allowed to see
Helper function to be used with getAllTagsUnique() and getAllTagsCount() or db queries only
Note if the Zenpage plugin is not enabled but items exists this returns no IDs so you need an extra check afterwards!
Returns
array
|
public
integer
|
#
getArticle( integer $index, $published = NULL, $sortorder = NULL, $sortdirection = NULL, $sticky = true )
Returns an article from the album based on the index passed.
Returns an article from the album based on the index passed.
Parameters
- $index
- $published
- $sortorder
- $sortdirection
- $sticky
Returns
integer
|
public static
string
|
#
getOffset( integer $articles_per_page, boolean $ignorepagination = false )
Gets the LIMIT and OFFSET for the query that gets the news articles
Gets the LIMIT and OFFSET for the query that gets the news articles
Parameters
- $articles_per_page
- The number of articles to get
- $ignorepagination
- If pagination should be ingored so always with the first is started (false is default)
Returns
string
|
public
|
#
getTotalArticles( )
Returns the articles count
Returns the articles count
Deprecated
since version 1.4.6
|
public
array
|
#
getAllArticleDates( boolean $yearsonly = false, string $order = 'desc' )
Retrieves a list of all unique years & months
Retrieves a list of all unique years & months
Parameters
- $yearsonly
- If set to true only the years' count is returned (Default false)
- $order
- 'desc' (default) or 'asc' for descending or ascending
Returns
array
|
protected
array
|
#
getCombiNews( integer $articles_per_page = '', string $mode = '', string $published = NULL, string $sortorder = NULL, boolean $sticky = true, string $sortdirection = 'desc' )
Gets news articles and images of a gallery to show them together on the news section
Gets news articles and images of a gallery to show them together on the news section
NOTE: This function does not exclude articles that are password protected via a category
Deprecated
since version 1.4.6
Parameters
- $articles_per_page
- The number of articles to get
- $mode
"latestimages-thumbnail"
"latestimages-thumbnail-customcrop"
"latestimages-sizedimage"
"latestalbums-thumbnail"
"latestalbums-thumbnail-customcrop"
"latestalbums-sizedimage"
"latestimagesbyalbum-thumbnail"
"latestimagesbyalbum-thumbnail-customcrop"
"latestimagesbyalbum-sizedimage"
"latestupdatedalbums-thumbnail" (for RSS and getLatestNews() used only)
"latestupdatedalbums-thumbnail-customcrop" (for RSS and getLatestNews() used only)
"latestupdatedalbums-sizedimage" (for RSS and getLatestNews() used only)
NOTE: The "latestupdatedalbums" variants do NOT support pagination as required on the news loop!
- $published
"published" for published articles,
"unpublished" for un-published articles,
"all" for all articles
- $sortorder
- id, date or mtime, only for latestimages-... modes
- $sticky
- set to true to place "sticky" articles at the front of the list.
- $sortdirection
- $direction "desc" or "asc"
Returns
array
|
public
string
|
#
getNewsIndexURL( )
Returns the full path of the news index page (news page 1) or if the "news on zp index" option is set a link to the gallery index.
Returns the full path of the news index page (news page 1) or if the "news on zp index" option is set a link to the gallery index.
Returns
string
|
public
string
|
#
getNewsCategoryPath( $category, $page = NULL )
Returns partial path of news category
Returns partial path of news category
Deprecated
since version 1.4.6
Returns
string
|
public
string
|
#
getNewsArchivePath( $date, $page = NULL )
Returns partial path of news date archive
Returns partial path of news date archive
Deprecated
since version 1.4.6
Returns
string
|
public
string
|
#
getNewsTitlePath( $title )
Returns partial path of news article title
Returns partial path of news article title
Deprecated
since version 1.4.6
Returns
string
|
public
string
|
#
getCategoryLink( string $catname )
Gets the category link of a category
Gets the category link of a category
Deprecated
since version 1.4.6
Parameters
- $catname
- the title of the category
Returns
string
|
public
array
|
#
getCategory( integer $id )
Gets a category titlelink by id
Gets a category titlelink by id
Parameters
Returns
array
|
public
array
|
#
getAllCategories( boolean $visible = true, string $sorttype = NULL, boolean $sortdirection = NULL )
Gets all categories
Parameters
- $visible
- TRUE for published and unprotected
- $sorttype
- NULL for the standard order as sorted on the backend, "title", "id", "popular", "random"
- $sortdirection
- TRUE for ascending or FALSE for descending order
Returns
array
|
public
string
|
#
__toString( )
"Magic" function to return a string identifying the object when it is treated as a string
Returns
string
|
public
|
|
public
|
|
public
|
|
public
|
|
public
|
|
public
|
|