API - XOOPS 2.5.11 Beta 2
By monxoops.fr
XoopsCommentRenderer Class Reference

Public Member Functions

 __construct (XoopsTpl $tpl, $use_icons=true, $do_iconcheck=false)
 
 setComments (&$comments_arr)
 
 renderFlatView ($admin_view=false)
 
 renderThreadView ($comment_id=0, $admin_view=false, $show_nav=true)
 
 _renderThreadReplies (&$thread, $key, &$replies, $prefix, $admin_view, $depth=0, $current_prefix='')
 
 renderNestView ($comment_id=0, $admin_view=false)
 
 _renderNestReplies (&$thread, $key, &$replies, $prefix, $admin_view, $depth=0)
 
 _getPosterName ($poster_id, $poster_user, $poster_website)
 
 _getPosterArray ($poster_id, $poster_user, $poster_website)
 
 _getTitleIcon ($icon_image)
 

Static Public Member Functions

static instance (XoopsTpl $tpl, $use_icons=true, $do_iconcheck=false)
 

Data Fields

 $_tpl
 
 $_comments
 
 $_useIcons = true
 
 $_doIconCheck = false
 
 $_memberHandler
 
 $_statusText
 

Detailed Description

Display comments

Author
Kazumi Ono onoka.nosp@m.zu@x.nosp@m.oops..nosp@m.org @access public

Constructor & Destructor Documentation

◆ __construct()

__construct ( XoopsTpl  $tpl,
  $use_icons = true,
  $do_iconcheck = false 
)

*#- Constructor

Parameters
XoopsTpl$tpl
boolean$use_icons
boolean$do_iconcheck
Here is the call graph for this function:

Member Function Documentation

◆ _getPosterArray()

_getPosterArray (   $poster_id,
  $poster_user,
  $poster_website 
)

Get an array with info about the poster

Parameters
int$poster_id
$poster_user
$poster_website
Returns
array @access private
Here is the call graph for this function:
Here is the caller graph for this function:

◆ _getPosterName()

_getPosterName (   $poster_id,
  $poster_user,
  $poster_website 
)

Get the name of the poster

Parameters
int$poster_id
$poster_user
$poster_website
Returns
string @access private
Here is the caller graph for this function:

◆ _getTitleIcon()

_getTitleIcon (   $icon_image)

Get the IMG tag for the title icon

Parameters
string$icon_image
Returns
string HTML IMG tag @access private
Here is the caller graph for this function:

◆ _renderNestReplies()

_renderNestReplies ( $thread,
  $key,
$replies,
  $prefix,
  $admin_view,
  $depth = 0 
)

Render replies in nested view

Parameters
array$thread
int$key
array$replies
string | int$prefix
bool$admin_view
integer$depth@access private
Here is the call graph for this function:
Here is the caller graph for this function:

◆ _renderThreadReplies()

_renderThreadReplies ( $thread,
  $key,
$replies,
  $prefix,
  $admin_view,
  $depth = 0,
  $current_prefix = '' 
)

Render replies to a thread

Parameters
array$thread
int$key
array$replies
string$prefix
bool$admin_view
integer$depth
string$current_prefix@access private
Here is the call graph for this function:
Here is the caller graph for this function:

◆ instance()

static instance ( XoopsTpl  $tpl,
  $use_icons = true,
  $do_iconcheck = false 
)
static

Access the only instance of this class

Parameters
XoopsTpl$tplreference to a Smarty object
boolean$use_icons
boolean$do_iconcheck
Returns
\XoopsCommentRenderer

◆ renderFlatView()

renderFlatView (   $admin_view = false)

Render the comments in flat view

Parameters
boolean$admin_view
Here is the call graph for this function:

◆ renderNestView()

renderNestView (   $comment_id = 0,
  $admin_view = false 
)

Render comments in nested view

Danger: Recursive!

Parameters
integer$comment_idAlways "0" when called by client.
boolean$admin_view
Returns
void
Here is the call graph for this function:
Here is the caller graph for this function:

◆ renderThreadView()

renderThreadView (   $comment_id = 0,
  $admin_view = false,
  $show_nav = true 
)

Render the comments in thread view

This method calls itself recursively

Parameters
integer$comment_idShould be "0" when called by client
boolean$admin_view
boolean$show_nav
Returns
void
Here is the call graph for this function:
Here is the caller graph for this function:

◆ setComments()

setComments ( $comments_arr)

Accessor

Parameters
array$comments_arrarray of XoopsComment objects

Field Documentation

◆ $_comments

$_comments

◆ $_doIconCheck

$_doIconCheck = false

◆ $_memberHandler

$_memberHandler

◆ $_statusText

$_statusText

◆ $_tpl

$_tpl

*#+

@access private

◆ $_useIcons

$_useIcons = true

The documentation for this class was generated from the following file: