[ class tree: plugins ] [ index: plugins ] [ all elements ]

Class: ZenpageNews

Source Location: /zp-extensions/zenpage/zenpage-class-news.php

Class ZenpageNews

Inherited Properties, Constants, and Methods
Inherited Properties Inherited Methods Inherited Constants

Inherited From PersistentObject

PersistentObject::$cache_by
PersistentObject::$data
PersistentObject::$id
PersistentObject::$loaded
PersistentObject::$table
PersistentObject::$transient
PersistentObject::$unique_set
PersistentObject::$updates
PersistentObject::$use_cache

Inherited From PersistentObject

PersistentObject::PersistentObject()
PersistentObject::cache()
Caches the current set of objects defined by a variable key $cache_by.
PersistentObject::copy()
Copy this record to another unique set. Checks if the record exists there first, if so returns false. If successful returns true. No changes are made to this object and no other objects are created, just the database entry.
PersistentObject::get()
Get the value of a variable. If $current is false, return the value as of the last save of this object.
PersistentObject::load()
Load the data array from the database, using the unique id set to get the unique record.
PersistentObject::move()
Change one or more values of the unique set assigned to this record.
PersistentObject::remove()
Deletes object from the database
PersistentObject::save()
Save the updates made to this object since the last update. Returns true if successful, false if not.
PersistentObject::set()
Set a variable in this object. Does not persist to the database until save() is called. So, IMPORTANT: Call save() after set() to persist.
PersistentObject::setDefaults()
Sets default values for new objects using the set() method.

[ Top ]
Property Summary
mixed   $commentcount  
mixed   $comments  

[ Top ]
Method Summary
ZenpageNews   ZenpageNews()  
object   addComment()   Adds a comment to the news article assumes data is coming straight from GET or POST
string   getAuthor()   Returns the author of the news article
array   getCategories()   Gets the categories assigned to an news article
array   getCodeblock()   Returns the codeblocks of the news article as an serialized array
int   getCommentCount()   Returns the count of comments for the current news article. Comments in moderation are not counted
array   getComments()   Returns an array of comments of the current news article
bool   getCommentsAllowed()   Returns true of comments are allowed
string   getContent()   Returns the content of the news article
string   getDateTime()   Returns the date of the news article
string   getExpireDate()   Returns the expire date of the news article
string   getExtraContent()   Returns the extra content of the news article
string   getHitcounter()   Returns the hitcount of the news article
string   getID()   Returns the id of the news article
string   getLastchange()   Returns the last change date of the news article
string   getLastchangeAuthor()   Returns the last change author of the news article
string   getLocked()   Returns the locked status of the news article, "1" if locked (only used on the admin)
string   getPermalink()   Returns the permalink status of the news article, "1" if enabled (only used on the admin)
string   getShow()   Returns the show status of the news article, "1" if published
string   getSortOrder()   Returns the news article title sortorder
string   getTags()   Returns the tag data of an album
string   getTitle()   Returns the title of the news article
string   getTitlelink()   Returns the titlelink of the news article
void   setTags()   Stores tag information of an album

[ Top ]
Properties
mixed   $commentcount [line 13]

[ Top ]
mixed   $comments = NULL [line 12]

[ Top ]
Methods
Constructor ZenpageNews  [line 15]

  ZenpageNews ZenpageNews( $titlelink  )

Parameters:
   $titlelink: 


[ Top ]
addComment  [line 260]

  object addComment( string $name, string $email, string $website, string $comment, string $code, string $code_ok, string $ip, bool $private, bool $anon  )

Adds a comment to the news article assumes data is coming straight from GET or POST

Returns a comment object

Parameters:
string   $name:  Comment author name
string   $email:  Comment author email
string   $website:  Comment author website
string   $comment:  body of the comment
string   $code:  CAPTCHA code entered
string   $code_ok:  CAPTCHA md5 expected
string   $ip:  the IP address of the comment poster
bool   $private:  set to true if the comment is for the admin only
bool   $anon:  set to true if the poster wishes to remain anonymous


[ Top ]
getAuthor  [line 99]

  string getAuthor( )

Returns the author of the news article



[ Top ]
getCategories  [line 163]

  array getCategories( int $article_id  )

Gets the categories assigned to an news article

Parameters:
int   $article_id:  ID od the article


[ Top ]
getCodeblock  [line 90]

  array getCodeblock( )

Returns the codeblocks of the news article as an serialized array



[ Top ]
getCommentCount  [line 271]

  int getCommentCount( )

Returns the count of comments for the current news article. Comments in moderation are not counted



[ Top ]
getComments  [line 224]

  array getComments( [bool $moderated = false], [bool $private = false], [bool $desc = false]  )

Returns an array of comments of the current news article

Parameters:
bool   $moderated:  if false, comments in moderation are ignored
bool   $private:  if false ignores private comments
bool   $desc:  set to true for descending order


[ Top ]
getCommentsAllowed  [line 213]

  bool getCommentsAllowed( )

Returns true of comments are allowed



[ Top ]
getContent  [line 45]

  string getContent( )

Returns the content of the news article



[ Top ]
getDateTime  [line 108]

  string getDateTime( )

Returns the date of the news article



[ Top ]
getExpireDate  [line 173]

  string getExpireDate( )

Returns the expire date of the news article



[ Top ]
getExtraContent  [line 54]

  string getExtraContent( )

Returns the extra content of the news article



[ Top ]
getHitcounter  [line 135]

  string getHitcounter( )

Returns the hitcount of the news article



[ Top ]
getID  [line 27]

  string getID( )

Returns the id of the news article



[ Top ]
getLastchange  [line 117]

  string getLastchange( )

Returns the last change date of the news article



[ Top ]
getLastchangeAuthor  [line 126]

  string getLastchangeAuthor( )

Returns the last change author of the news article



[ Top ]
getLocked  [line 144]

  string getLocked( )

Returns the locked status of the news article, "1" if locked (only used on the admin)



[ Top ]
getPermalink  [line 153]

  string getPermalink( )

Returns the permalink status of the news article, "1" if enabled (only used on the admin)



[ Top ]
getShow  [line 72]

  string getShow( )

Returns the show status of the news article, "1" if published



[ Top ]
getSortOrder  [line 63]

  string getSortOrder( )

Returns the news article title sortorder



[ Top ]
getTags  [line 187]

  string getTags( )

Returns the tag data of an album



[ Top ]
getTitle  [line 36]

  string getTitle( )

Returns the title of the news article



[ Top ]
getTitlelink  [line 81]

  string getTitlelink( )

Returns the titlelink of the news article



[ Top ]
setTags  [line 196]

  void setTags( string $tags  )

Stores tag information of an album

Parameters:
string   $tags:  the tag list


[ Top ]

Documentation generated on Mon, 09 Aug 2010 17:24:18 +0200 by phpDocumentor 1.4.1