source: extensions/bbcode_bar/main.inc.php @ 5547

Last change on this file since 5547 was 3609, checked in by patdenice, 15 years ago

Convert all php and tpl files in Unix format for my plugins.

File size: 1.0 KB
RevLine 
[3609]1<?php /*
2Plugin Name: BBCode_bar
3Version: 2.0.a
4Description: Allow use BBCode for comments and descriptions. / Permet d'utiliser du BBCode pour les commentaires et les descriptions.
5Plugin URI: http://phpwebgallery.net/ext/extension_view.php?eid=140
6Author: Atadilo
7Author URI: http://www.phpwebgallery.net
8*/
9
10if (!defined('PHPWG_ROOT_PATH')) die('Hacking attempt!');
11
12include_once(dirname(__FILE__).'/bbcode_bar.inc.php');
13
14add_event_handler('init', 'init_bbcode_bar');
15
16function init_bbcode_bar()
17{
18  remove_event_handler('render_comment_content', 'parse_comment_content' );
19  add_event_handler('render_comment_content', 'BBCodeParse');
20  add_event_handler('loc_begin_picture', 'set_bbcode_bar');
21}
22
23if (script_basename() == 'admin')
24{
25  add_event_handler('get_admin_plugin_menu_links', 'bbcode_bar_admin_menu');
26 
27  function bbcode_bar_admin_menu($menu)
28  {
29    array_push($menu,
30      array('NAME' => 'BBCode_Bar',
31            'URL' => get_admin_plugin_menu_link(dirname(__FILE__) . '/bbcode_bar_admin.php')));
32    return $menu;
33  }
34}
[3305]35?>
Note: See TracBrowser for help on using the repository browser.