Changeset 32181 for extensions
- Timestamp:
- May 6, 2020, 10:07:34 PM (4 years ago)
- Location:
- extensions/Photo_add_by
- Files:
-
- 6 edited
Legend:
- Unmodified
- Added
- Removed
-
extensions/Photo_add_by/admin.php
r31465 r32181 1 1 <?php 2 2 // +-----------------------------------------------------------------------+ 3 // | Photo added by plugin for Piwigo 3 // | Photo added by plugin for Piwigo by TEMMII | 4 4 // +-----------------------------------------------------------------------+ 5 // | Copyright(C) 2012-20 16ddtddt http://temmii.com/piwigo/ |5 // | Copyright(C) 2012-2020 ddtddt http://temmii.com/piwigo/ | 6 6 // +-----------------------------------------------------------------------+ 7 7 // | This program is free software; you can redistribute it and/or modify | -
extensions/Photo_add_by/initpicture.php
r31465 r32181 1 1 <?php 2 2 // +-----------------------------------------------------------------------+ 3 // | Photo added by plugin for Piwigo 3 // | Photo added by plugin for Piwigo by TEMMII | 4 4 // +-----------------------------------------------------------------------+ 5 // | Copyright(C) 2012-20 16ddtddt http://temmii.com/piwigo/ |5 // | Copyright(C) 2012-2020 ddtddt http://temmii.com/piwigo/ | 6 6 // +-----------------------------------------------------------------------+ 7 7 // | This program is free software; you can redistribute it and/or modify | … … 22 22 //Ajout du prefiltre 23 23 add_event_handler('loc_begin_picture', 'pabI', 55 ); 24 25 function pabI() 26 { 24 function pabI(){ 27 25 global $template; 28 26 $template->set_prefilter('picture', 'pabIT'); 29 27 } 30 28 31 32 function pabIT($content, &$smarty) 33 { 34 35 global $conf; 36 37 $search = '#<div id="'.$conf['Photo_add_by'].'" class="imageInfo">#'; 38 39 $replacement = ' 29 function pabIT($content, &$smarty){ 30 global $conf, $pwg_loaded_plugins; 31 $search = '#<div id="'.$conf['Photo_add_by'].'" class="imageInfo">#'; 32 if (isset($pwg_loaded_plugins['manage_properties_photos'])){ 33 $replacement = '<div id="'.$conf['Photo_add_by'].'" class="imageInfo">'; 34 }else{ 35 $replacement = ' 40 36 {if $PAB} 41 37 <div id="pab1" class="imageInfo"> … … 45 41 {/if} 46 42 <div id="'.$conf['Photo_add_by'].'" class="imageInfo">'; 47 43 } 48 44 return preg_replace($search, $replacement, $content); 49 45 } -
extensions/Photo_add_by/language/en_UK/plugin.lang.php
r31465 r32181 1 1 <?php 2 2 // +-----------------------------------------------------------------------+ 3 // | Photo added by plugin for Piwigo 3 // | Photo added by plugin for Piwigo by TEMMII | 4 4 // +-----------------------------------------------------------------------+ 5 // | Copyright(C) 2012-20 16ddtddt http://temmii.com/piwigo/ |5 // | Copyright(C) 2012-2020 ddtddt http://temmii.com/piwigo/ | 6 6 // +-----------------------------------------------------------------------+ 7 7 // | This program is free software; you can redistribute it and/or modify | … … 19 19 // | USA. | 20 20 // +-----------------------------------------------------------------------+ 21 21 22 $lang['Photo added by'] = 'Photo added by'; 22 23 $lang['Add information before'] = 'Add information before'; -
extensions/Photo_add_by/language/fr_FR/plugin.lang.php
r31465 r32181 1 1 <?php 2 2 // +-----------------------------------------------------------------------+ 3 // | Photo added by plugin for Piwigo 3 // | Photo added by plugin for Piwigo by TEMMII | 4 4 // +-----------------------------------------------------------------------+ 5 // | Copyright(C) 2012-20 16ddtddt http://temmii.com/piwigo/ |5 // | Copyright(C) 2012-2020 ddtddt http://temmii.com/piwigo/ | 6 6 // +-----------------------------------------------------------------------+ 7 7 // | This program is free software; you can redistribute it and/or modify | … … 19 19 // | USA. | 20 20 // +-----------------------------------------------------------------------+ 21 21 22 $lang['Photo added by'] = 'Photo Ajoutée par'; 22 23 $lang['Add information before'] = 'Ajouter l\'information avant'; -
extensions/Photo_add_by/main.inc.php
r31465 r32181 2 2 /* 3 3 Plugin Name: Photo added by 4 Version: auto4 Version: 2.9.a 5 5 Description: Add who added photo on photo page 6 6 Plugin URI: http://piwigo.org/ext/extension_view.php?eid=621 … … 10 10 11 11 // +-----------------------------------------------------------------------+ 12 // | Photo added by plugin for Piwigo 12 // | Photo added by plugin for Piwigo by TEMMII | 13 13 // +-----------------------------------------------------------------------+ 14 // | Copyright(C) 2012-20 16ddtddt http://temmii.com/piwigo/ |14 // | Copyright(C) 2012-2020 ddtddt http://temmii.com/piwigo/ | 15 15 // +-----------------------------------------------------------------------+ 16 16 // | This program is free software; you can redistribute it and/or modify | … … 31 31 if (!defined('PHPWG_ROOT_PATH')) die('Hacking attempt!'); 32 32 33 global $prefixeTable ;33 global $prefixeTable, $pwg_loaded_plugins; 34 34 35 35 define('PAB_DIR' , basename(dirname(__FILE__))); … … 50 50 add_event_handler('get_admin_plugin_menu_links', 'PAB_admin_menu'); 51 51 function PAB_admin_menu($menu){ 52 $menu[] = array( 53 'NAME' => l10n('Photo added by'), 54 'URL' => PAB_ADMIN, 55 ); 52 global $pwg_loaded_plugins; 53 if (is_webmaster()){ 54 if(isset($pwg_loaded_plugins['manage_properties_photos'])){}else{ 55 $menu[] = array( 56 'NAME' => l10n('Photo added by'), 57 'URL' => PAB_ADMIN, 58 ); 59 } 60 } 56 61 return $menu; 57 62 } -
extensions/Photo_add_by/maintain.class.php
r31605 r32181 1 1 <?php 2 2 // +-----------------------------------------------------------------------+ 3 // | Photo added by plugin for Piwigo 3 // | Photo added by plugin for Piwigo by TEMMII | 4 4 // +-----------------------------------------------------------------------+ 5 // | Copyright(C) 2012-20 16ddtddt http://temmii.com/piwigo/ |5 // | Copyright(C) 2012-2020 ddtddt http://temmii.com/piwigo/ | 6 6 // +-----------------------------------------------------------------------+ 7 7 // | This program is free software; you can redistribute it and/or modify | … … 19 19 // | USA. | 20 20 // +-----------------------------------------------------------------------+ 21 21 22 defined('PHPWG_ROOT_PATH') or die('Hacking attempt!'); 22 23 … … 46 47 conf_update_param('Photo_add_by_show',0,true); 47 48 } 49 $template->delete_compiled_templates(array('picture' => 'picture.tpl')); 48 50 } 49 51 … … 63 65 function deactivate() 64 66 { 67 $template->delete_compiled_templates(array('picture' => 'picture.tpl')); 65 68 } 66 69
Note: See TracChangeset
for help on using the changeset viewer.