You are here

function activeedit_comment in Javascript Tools 5

Implementation of hook_comment().

1 call to activeedit_comment()
user_activeedit_links in activeedit/modules/comment.inc

File

activeedit/modules/comment.inc, line 6

Code

function activeedit_comment(&$comment, $op) {
  static $output;
  switch ($op) {
    case 'view':
      if (comment_access('edit', $comment)) {
        $comment->comment .= activeedit_comment_data_form($comment);
      }
      break;
    case 'insert':
    case 'update':
      if ($key = $_REQUEST['activeedit_id'] && ($type = $_REQUEST['activeedit_type'])) {
        $null = NULL;
        $output = comment_render($null, $comment['cid']);
      }
      break;
    case 'activeedit':
      return $output;
      break;
  }
}