source: extensions/edit_gmaps/main.inc.php @ 8194

Last change on this file since 8194 was 6445, checked in by cljosse, 14 years ago

[Edit_gmaps] update for version piwigo 2.1

File size: 1.6 KB
RevLine 
[4547]1<?php /*
2Plugin Name: Edit Maps&Earth
[6445]3Version: 2.1.0
[4558]4Description:  Editor for rv gmaps
[4557]5Plugin URI: http://piwigo.org/ext/extension_view.php?eid=330
[4547]6Author: rvelices cljosse
[4558]7Author URI: http://cl.josse.free.fr/
[4547]8*/
[4558]9
[6445]10define( 'ed_rvm_PLUGIN_VERSION', '2.1.0');
[4547]11if (!defined('PHPWG_ROOT_PATH')) die('Hacking attempt!');
12add_event_handler('get_admin_plugin_menu_links', 'ed_rvm_plugin_admin_menu' );
13
14global $ed_rvm_dir;
15$ed_rvm_dir = basename( dirname(__FILE__) );
16
[4559]17
[6445]18
[4547]19function ed_rvm_plugin_admin_menu($menu)
20{
21//      include_once( dirname(__FILE__) .'/include/functions.php');
22        add_event_handler('invalidate_user_cache', 'rvm_invalidate_cache' );
23
24        array_push($menu,
25                        array(
[4558]26                       
[4547]27                                'NAME' => 'EDIT Maps & Earth',
28                                'URL' => get_admin_plugin_menu_link(dirname(__FILE__).'/admin/admin.php')
29                        )
30                );
31        return $menu;
32}
[4556]33 
34add_event_handler('loc_after_page_header', 'cl_conflit');
35function cl_conflit() {
36  global $template,$page;
37 
[6445]38 if (file_exists ( 'themes/default/js/jquery.packed.js')) 
39{
40//version 2.1
[4557]41 
[6445]42   $icon_path = 'themes/default/icon/help.png';
43   $path_js=  'themes/default/js/' ; 
44
45 }
46 else
47 {
48// version < 1.9
49  $path_js=  "template-common/lib/"; 
50  $icon_path =  "admin/template/goto/theme/clear/icon/help.png";
51}
[4558]52 if (   isset($_GET['map'])   )
[4556]53{
[6445]54//===================================================================================
55$template->assign(
56    array(      'path_js' => $path_js,
[4558]57
[6445]58              ) 
59  );
[4557]60 $template->set_filenames(array('cl_conflit' => dirname(__FILE__).'/template/cl_conflit.tpl'));
[4556]61 $template->parse('cl_conflit');
[4557]62}else{
[4556]63 
64}
[4557]65 return ; 
66}
[4547]67
[4556]68
[4547]69?>
Note: See TracBrowser for help on using the repository browser.