Changeset 31461


Ignore:
Timestamp:
03/19/16 07:24:59 (4 years ago)
Author:
ddtddt
Message:

[extensions] - PersoAbout - 2.8

Location:
extensions/PersoAbout
Files:
2 deleted
6 edited

Legend:

Unmodified
Added
Removed
  • extensions/PersoAbout/index.php

    r8115 r31461  
    11<?php 
    2 // +-----------------------------------------------------------------------+ 
    3 // | Piwigo - a PHP based picture gallery                                  | 
    4 // +-----------------------------------------------------------------------+ 
    5 // | Copyright(C) 2008-2009 Piwigo Team                  http://piwigo.org | 
    6 // | Copyright(C) 2003-2008 PhpWebGallery Team    http://phpwebgallery.net | 
    7 // | Copyright(C) 2002-2003 Pierrick LE GALL   http://le-gall.net/pierrick | 
    8 // +-----------------------------------------------------------------------+ 
    9 // | This program is free software; you can redistribute it and/or modify  | 
    10 // | it under the terms of the GNU General Public License as published by  | 
    11 // | the Free Software Foundation                                          | 
    12 // |                                                                       | 
    13 // | This program is distributed in the hope that it will be useful, but   | 
    14 // | WITHOUT ANY WARRANTY; without even the implied warranty of            | 
    15 // | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU      | 
    16 // | General Public License for more details.                              | 
    17 // |                                                                       | 
    18 // | You should have received a copy of the GNU General Public License     | 
    19 // | along with this program; if not, write to the Free Software           | 
    20 // | Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, | 
    21 // | USA.                                                                  | 
    22 // +-----------------------------------------------------------------------+ 
    23  
    242// Recursive call 
    253$url = '../'; 
  • extensions/PersoAbout/language/en_UK/index.php

    r8115 r31461  
    11<?php 
    2 // +-----------------------------------------------------------------------+ 
    3 // | Piwigo - a PHP based picture gallery                                  | 
    4 // +-----------------------------------------------------------------------+ 
    5 // | Copyright(C) 2008-2009 Piwigo Team                  http://piwigo.org | 
    6 // | Copyright(C) 2003-2008 PhpWebGallery Team    http://phpwebgallery.net | 
    7 // | Copyright(C) 2002-2003 Pierrick LE GALL   http://le-gall.net/pierrick | 
    8 // +-----------------------------------------------------------------------+ 
    9 // | This program is free software; you can redistribute it and/or modify  | 
    10 // | it under the terms of the GNU General Public License as published by  | 
    11 // | the Free Software Foundation                                          | 
    12 // |                                                                       | 
    13 // | This program is distributed in the hope that it will be useful, but   | 
    14 // | WITHOUT ANY WARRANTY; without even the implied warranty of            | 
    15 // | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU      | 
    16 // | General Public License for more details.                              | 
    17 // |                                                                       | 
    18 // | You should have received a copy of the GNU General Public License     | 
    19 // | along with this program; if not, write to the Free Software           | 
    20 // | Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, | 
    21 // | USA.                                                                  | 
    22 // +-----------------------------------------------------------------------+ 
    23  
    242// Recursive call 
    253$url = '../'; 
  • extensions/PersoAbout/language/en_UK/plugin.lang.php

    r26200 r31461  
    11<?php 
     2// +-----------------------------------------------------------------------+ 
     3// | Perso About plugin for piwigo                                         | 
     4// +-----------------------------------------------------------------------+ 
     5// | Copyright(C) 2010 - 2016 ddtddt             http://temmii.com/piwigo/ | 
     6// +-----------------------------------------------------------------------+ 
     7// | This program is free software; you can redistribute it and/or modify  | 
     8// | it under the terms of the GNU General Public License as published by  | 
     9// | the Free Software Foundation                                          | 
     10// |                                                                       | 
     11// | This program is distributed in the hope that it will be useful, but   | 
     12// | WITHOUT ANY WARRANTY; without even the implied warranty of            | 
     13// | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU      | 
     14// | General Public License for more details.                              | 
     15// |                                                                       | 
     16// | You should have received a copy of the GNU General Public License     | 
     17// | along with this program; if not, write to the Free Software           | 
     18// | Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, | 
     19// | USA.                                                                  | 
     20// +-----------------------------------------------------------------------+ 
    221$lang['ppa_h2'] = 'Personal About'; 
    322 
  • extensions/PersoAbout/language/fr_FR/index.php

    r8115 r31461  
    11<?php 
    2 // +-----------------------------------------------------------------------+ 
    3 // | Piwigo - a PHP based picture gallery                                  | 
    4 // +-----------------------------------------------------------------------+ 
    5 // | Copyright(C) 2008-2009 Piwigo Team                  http://piwigo.org | 
    6 // | Copyright(C) 2003-2008 PhpWebGallery Team    http://phpwebgallery.net | 
    7 // | Copyright(C) 2002-2003 Pierrick LE GALL   http://le-gall.net/pierrick | 
    8 // +-----------------------------------------------------------------------+ 
    9 // | This program is free software; you can redistribute it and/or modify  | 
    10 // | it under the terms of the GNU General Public License as published by  | 
    11 // | the Free Software Foundation                                          | 
    12 // |                                                                       | 
    13 // | This program is distributed in the hope that it will be useful, but   | 
    14 // | WITHOUT ANY WARRANTY; without even the implied warranty of            | 
    15 // | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU      | 
    16 // | General Public License for more details.                              | 
    17 // |                                                                       | 
    18 // | You should have received a copy of the GNU General Public License     | 
    19 // | along with this program; if not, write to the Free Software           | 
    20 // | Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, | 
    21 // | USA.                                                                  | 
    22 // +-----------------------------------------------------------------------+ 
    23  
    242// Recursive call 
    253$url = '../'; 
  • extensions/PersoAbout/language/fr_FR/plugin.lang.php

    r26220 r31461  
    11<?php 
    2 $lang['ppa_h2'] = 'Personal About'; 
     2// +-----------------------------------------------------------------------+ 
     3// | Perso About plugin for piwigo                                         | 
     4// +-----------------------------------------------------------------------+ 
     5// | Copyright(C) 2010 - 2016 ddtddt             http://temmii.com/piwigo/ | 
     6// +-----------------------------------------------------------------------+ 
     7// | This program is free software; you can redistribute it and/or modify  | 
     8// | it under the terms of the GNU General Public License as published by  | 
     9// | the Free Software Foundation                                          | 
     10// |                                                                       | 
     11// | This program is distributed in the hope that it will be useful, but   | 
     12// | WITHOUT ANY WARRANTY; without even the implied warranty of            | 
     13// | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU      | 
     14// | General Public License for more details.                              | 
     15// |                                                                       | 
     16// | You should have received a copy of the GNU General Public License     | 
     17// | along with this program; if not, write to the Free Software           | 
     18// | Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, | 
     19// | USA.                                                                  | 
     20// +-----------------------------------------------------------------------+ 
     21$lang['ppa_h2'] = 'A propos personel'; 
    322 
    423//Tab gest 
  • extensions/PersoAbout/main.inc.php

    r29790 r31461  
    66Plugin URI: http://piwigo.org/ext/extension_view.php?eid=480 
    77Author: ddtddt 
    8 Author URI: http://piwigo.org/ 
     8Author URI: http://temmii.com/piwigo/ 
    99*/ 
     10// +-----------------------------------------------------------------------+ 
     11// | Perso About plugin for piwigo                                         | 
     12// +-----------------------------------------------------------------------+ 
     13// | Copyright(C) 2010 - 2016 ddtddt             http://temmii.com/piwigo/ | 
     14// +-----------------------------------------------------------------------+ 
     15// | This program is free software; you can redistribute it and/or modify  | 
     16// | it under the terms of the GNU General Public License as published by  | 
     17// | the Free Software Foundation                                          | 
     18// |                                                                       | 
     19// | This program is distributed in the hope that it will be useful, but   | 
     20// | WITHOUT ANY WARRANTY; without even the implied warranty of            | 
     21// | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU      | 
     22// | General Public License for more details.                              | 
     23// |                                                                       | 
     24// | You should have received a copy of the GNU General Public License     | 
     25// | along with this program; if not, write to the Free Software           | 
     26// | Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, | 
     27// | USA.                                                                  | 
     28// +-----------------------------------------------------------------------+ 
    1029 
    1130if (!defined('PHPWG_ROOT_PATH')) die('Hacking attempt!'); 
     
    1332define('PPA_DIR' , basename(dirname(__FILE__))); 
    1433define('PPA_PATH' , PHPWG_PLUGINS_PATH . PPA_DIR . '/'); 
     34define('PPA_ADMIN',get_root_url().'admin.php?page=plugin-'.PPA_DIR); 
     35 
     36add_event_handler('loading_lang', 'perso_about_loading_lang');     
     37function perso_about_loading_lang(){ 
     38  load_language('plugin.lang', PPA_PATH); 
     39} 
    1540 
    1641add_event_handler('get_admin_plugin_menu_links', 'PA_admin_menu'); 
    17 function PA_admin_menu($menu) 
    18 { 
     42function PA_admin_menu($menu){ 
    1943  array_push($menu, array( 
    20         'NAME' => 'Perso About', 
    21     'URL' => get_admin_plugin_menu_link(PPA_PATH . 'admin/admin.php'))); 
     44        'NAME' => l10n('ppa_h2'), 
     45    'URL' => get_admin_plugin_menu_link(PPA_PATH . 'admin.php'))); 
    2246  return $menu; 
    2347} 
    2448 
    25  if (script_basename() == 'about') 
    26         { 
     49if (script_basename() == 'about'){ 
    2750  add_event_handler('loc_end_page_header', 'ppa'); 
    28         } 
     51} 
    2952 
    30 function ppa() 
    31  { 
    32         global $template, $conf; 
    33         $template->set_prefilter('about', 'ppaT'); 
    34          
    35 $PAED = pwg_db_fetch_assoc(pwg_query("SELECT state FROM " . PLUGINS_TABLE . " WHERE id = 'ExtendedDescription';")); 
    36 if($PAED['state'] == 'active') add_event_handler('AP_render_content', 'get_user_language_desc'); 
     53function ppa(){ 
     54  global $template, $conf; 
     55  $template->set_prefilter('about', 'ppaT'); 
     56  $PAED = pwg_db_fetch_assoc(pwg_query("SELECT state FROM " . PLUGINS_TABLE . " WHERE id = 'ExtendedDescription';")); 
     57  if($PAED['state'] == 'active') add_event_handler('AP_render_content', 'get_user_language_desc'); 
     58  $pat=trigger_change('AP_render_content', $conf['persoAbout']); 
     59  if (!empty($pat)){ 
     60        $template->assign('PERSO_ABOUT', $pat); 
     61  } 
     62} 
    3763 
    38 $pat=trigger_change('AP_render_content', $conf['persoAbout']); 
    39                  if (!empty($pat)) 
    40                         { 
    41                                 $template->assign('PERSO_ABOUT', $pat); 
    42                         } 
    43          
    44  } 
    45  
    46 function ppaT($content, &$smarty) 
    47  { 
     64function ppaT($content, &$smarty){ 
    4865  $search = '{$ABOUT_MESSAGE}'; 
    4966  $replacement = '<div id="persoabout">{$PERSO_ABOUT}</div> 
Note: See TracChangeset for help on using the changeset viewer.