ZenphotoCMS 1.6.2

feed
in package

Base feed class from which all others descend.

Plugins will set the feedtype property to the feed desired

  • gallery
  • news
  • pages
  • comments

Feed details are determined by the option property. Elements of this array and their meaning follow:

  • lang
    • locale
  • sortdir
    • desc (default) for descending order
    • asc for ascending order
  • sortorder
    • latest (default) for the latest uploaded by id (discovery order)
    • latest-date for the latest fetched by date
    • latest-mtime for the latest fetched by mtime
    • latest-publishdate for the latest fetched by publishdate
    • popular for the most popular albums
    • topratedv for the best voted
    • mostrated for the most voted
    • random for random order
    • id internal id order
  • albumname
  • albumsmode
  • folder
  • size
  • category
  • id
  • itemnumber
  • type (for comments feed)
    • albums
    • images
    • pages
    • news

Table of Contents

Properties

$albumfolder  : mixed
$albumpath  : mixed
$catlink  : mixed
$cattitle  : mixed
$channel_title  : mixed
$collection  : mixed
$commentfeedtype  : mixed
$feed  : mixed
$feeditem  : mixed
$feedtype  : mixed
$id  : mixed
$imagepath  : mixed
$imagesize  : mixed
$itemnumber  : mixed
$itemobj  : mixed
$locale  : mixed
$locale_xml  : mixed
$mode  : mixed
$modrewritesuffix  : mixed
$newsoption  : mixed
$options  : mixed
$sortdirection  : mixed
$sortorder  : mixed
$titleappendix  : mixed

Methods

__construct()  : mixed
clearCache()  : mixed
Cleans out the cache folder
getitems()  : array<string|int, mixed>
Gets the feed items
endCache()  : mixed
Ends the static caching.
feed404()  : mixed
getAlbum()  : int
Validates and gets the "folder" or 'albumname" parameter option value
getCacheFilename()  : string
Creates a file name from the options array
getCategory()  : int
Validates and gets the "category" parameter option value
getChannelTitleExtra()  : mixed
getCommentFeedType()  : string
Validates and gets the "type" parameter option value for comment feeds
getID()  : int
Validates and gets the "id" parameter option value for comments feeds of a specific item
getImageSize()  : string
Helper function that gets the images size of the "size" get parameter
getitemComments()  : array<string|int, mixed>
Gets the feed item data in a comments feed
getitemPages()  : array<string|int, mixed>
Gets the feed item data in a Zenpage news feed
getLang()  : string
Validates and gets the "lang" parameter option value
getSortdir()  : bool
Validates and gets the "sortdir" parameter option value
getSortorder()  : string
Validates and gets the "sortorder" parameter option value
startCache()  : mixed
Starts static caching
unsetOptions()  : mixed
Unsets certain option name indices from the $options property.

Properties

$albumfolder

protected mixed $albumfolder = \NULL

$channel_title

protected mixed $channel_title = \NULL

$commentfeedtype

protected mixed $commentfeedtype = \NULL

$modrewritesuffix

protected mixed $modrewritesuffix = \NULL

$sortdirection

protected mixed $sortdirection = \NULL

$titleappendix

protected mixed $titleappendix = \NULL

Methods

__construct()

public __construct(mixed $options) : mixed
Parameters
$options : mixed

clearCache()

Cleans out the cache folder

public clearCache([string $cachefolder = NULL ]) : mixed
Parameters
$cachefolder : string = NULL

the sub-folder to clean

getitems()

Gets the feed items

public getitems() : array<string|int, mixed>
Return values
array<string|int, mixed>

endCache()

Ends the static caching.

protected endCache() : mixed

getAlbum()

Validates and gets the "folder" or 'albumname" parameter option value

protected getAlbum(string $option) : int
Parameters
$option : string

"folder" or "albumname"

Return values
int

getCacheFilename()

Creates a file name from the options array

protected getCacheFilename() : string
Return values
string

getCategory()

Validates and gets the "category" parameter option value

protected getCategory() : int
Return values
int

getChannelTitleExtra()

protected getChannelTitleExtra() : mixed

getCommentFeedType()

Validates and gets the "type" parameter option value for comment feeds

protected getCommentFeedType() : string
Return values
string

getID()

Validates and gets the "id" parameter option value for comments feeds of a specific item

protected getID() : int
Return values
int

getImageSize()

Helper function that gets the images size of the "size" get parameter

protected getImageSize() : string
Return values
string

getitemComments()

Gets the feed item data in a comments feed

protected getitemComments(array<string|int, mixed> $item) : array<string|int, mixed>
Parameters
$item : array<string|int, mixed>

Array of a comment

Return values
array<string|int, mixed>

getitemPages()

Gets the feed item data in a Zenpage news feed

protected getitemPages(array<string|int, mixed> $item, mixed $len) : array<string|int, mixed>
Parameters
$item : array<string|int, mixed>

Titlelink a Zenpage article or filename of an image if a combined feed

$len : mixed
Return values
array<string|int, mixed>

getLang()

Validates and gets the "lang" parameter option value

protected getLang() : string
Tags
global

array $_zp_active_languages

Return values
string

getSortdir()

Validates and gets the "sortdir" parameter option value

protected getSortdir() : bool
Return values
bool

getSortorder()

Validates and gets the "sortorder" parameter option value

protected getSortorder() : string
Return values
string

startCache()

Starts static caching

protected startCache() : mixed

unsetOptions()

Unsets certain option name indices from the $options property.

protected unsetOptions([array<string|int, mixed> $options = null ]) : mixed
Parameters
$options : array<string|int, mixed> = null

Array of option (parameter) names to be unset


        
On this page

Search results