source: trunk/plugins/add_index/main.normal.inc.php @ 2126

Last change on this file since 2126 was 2126, checked in by rvelices, 17 years ago
  • some code refactoring before upgrade to utf (only cosmetic at this point...)
  • Property svn:eol-style set to LF
  • Property svn:keywords set to Author Date Id Revision
File size: 2.3 KB
Line 
1<?php
2// +-----------------------------------------------------------------------+
3// | PhpWebGallery - a PHP based picture gallery                           |
4// | Copyright (C) 2002-2003 Pierrick LE GALL - pierrick@phpwebgallery.net |
5// | Copyright (C) 2003-2007 PhpWebGallery Team - http://phpwebgallery.net |
6// +-----------------------------------------------------------------------+
7// | file          : $Id: main.normal.inc.php 2126 2007-10-08 23:46:09Z rvelices $
8// | last update   : $Date: 2007-10-08 23:46:09 +0000 (Mon, 08 Oct 2007) $
9// | last modifier : $Author: rvelices $
10// | revision      : $Revision: 2126 $
11// +-----------------------------------------------------------------------+
12// | This program is free software; you can redistribute it and/or modify  |
13// | it under the terms of the GNU General Public License as published by  |
14// | the Free Software Foundation                                          |
15// |                                                                       |
16// | This program is distributed in the hope that it will be useful, but   |
17// | WITHOUT ANY WARRANTY; without even the implied warranty of            |
18// | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU      |
19// | General Public License for more details.                              |
20// |                                                                       |
21// | You should have received a copy of the GNU General Public License     |
22// | along with this program; if not, write to the Free Software           |
23// | Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, |
24// | USA.                                                                  |
25// +-----------------------------------------------------------------------+
26
27if (!defined('PHPWG_ROOT_PATH'))
28{
29  die('Hacking attempt!');
30}
31
32class NormalAddIndex extends AddIndex
33{
34  function get_popup_help_content($popup_help_content, $page)
35  {
36    if (in_array($page, array('advanced_feature', 'site_manager')))
37    {
38      $help_content =
39        load_language('help/'.$page.'.html', $this->path, '', true);
40    }
41    else
42    {
43      $help_content = false;
44    }
45
46    if ($help_content == false)
47    {
48      return $popup_help_content;
49    }
50    else
51    {
52      return $popup_help_content.$help_content;
53    }
54  }
55}
56
57// Create object
58$add_index = new NormalAddIndex();
59
60// Add events
61add_event_handler('get_popup_help_content', array(&$add_index, 'get_popup_help_content'), EVENT_HANDLER_PRIORITY_NEUTRAL, 2);
62
63?>
Note: See TracBrowser for help on using the repository browser.