/[drupal]/contributions/modules/bbcode_wysiwyg/bbcode_wysiwyg.module
ViewVC logotype

Diff of /contributions/modules/bbcode_wysiwyg/bbcode_wysiwyg.module

Parent Directory Parent Directory | Revision Log Revision Log | View Revision Graph Revision Graph | View Patch Patch

revision 1.4.4.6, Mon Apr 14 18:40:02 2008 UTC revision 1.4.4.7, Tue Apr 29 04:03:50 2008 UTC
# Line 1  Line 1 
1  <?php  <?php
2  // $Id: bbcode_wysiwyg.module,v 1.4.4.5 2008/04/14 17:13:36 jrbeeman Exp $  // $Id: bbcode_wysiwyg.module,v 1.4.4.6 2008/04/14 18:40:02 jrbeeman Exp $
3    
4  /**  /**
5   * Implementation of hook_perm().   * Implementation of hook_perm().
# Line 160  function bbcode_wysiwyg_link($type, $nod Line 160  function bbcode_wysiwyg_link($type, $nod
160    
161    
162  /**  /**
163     * Implementation of hook_nodeapi().
164     */
165    function bbcode_wysiwyg_nodeapi(&$node, $op, $teaser = NULL, $page = NULL) {
166      switch ($op) {
167        case 'view':
168          $node->content['bbcode-username'] = array(
169            '#value' => theme('bbcode_wysiwyg_username', $node->name),
170            '#weight' => 1,
171          );
172          break;
173      }
174    }
175    
176    
177    
178    /**
179   * Implementation of hook_comment().   * Implementation of hook_comment().
180   */   */
181  function bbcode_comment(&$a1, $op) {  function bbcode_wysiwyg_comment(&$a1, $op) {
182    if ($op == 'view') {    if ($op == 'view') {
183      $a1->comment .= '<div class="bbcode-username" style="display:none;">'. $a1->name .'</div>';      $a1->comment .= theme('bbcode_wysiwyg_username', $a1->name);
184    }    }
185  }  }
186    
187    
188    function theme_bbcode_wysiwyg_username($name) {
189      return '<div class="bbcode-username" style="display:none;">'. $name .'</div>';
190    }
191    

Legend:
Removed from v.1.4.4.6  
changed lines
  Added in v.1.4.4.7

  ViewVC Help
Powered by ViewVC 1.1.2