Changeset 23473


Ignore:
Timestamp:
Jun 23, 2013, 7:54:28 PM (8 years ago)
Author:
mistic100
Message:

stores datas in piwigo _data

Location:
extensions/plugin_lang_analysis
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • extensions/plugin_lang_analysis/admin.php

    r23472 r23473  
    3434  }
    3535 
    36   if (file_exists(PLA_PATH.'_data/'.$_GET['plugin_id'].'.php'))
    37   {
    38     $saved_files = include(PLA_PATH.'_data/'.$_GET['plugin_id'].'.php');
     36  if (file_exists(PLA_DATA.$_GET['plugin_id'].'.php'))
     37  {
     38    $saved_files = include(PLA_DATA.$_GET['plugin_id'].'.php');
    3939  }
    4040  else
     
    9595    $content.= ";\n?>";
    9696   
    97     @mkdir(PLA_PATH.'_data/', true, 0755);
    98     file_put_contents(PLA_PATH.'_data/'.$_GET['plugin_id'].'.php', $content);
     97    @mkdir(PLA_DATA, true, 0755);
     98    file_put_contents(PLA_DATA.$_GET['plugin_id'].'.php', $content);
    9999  }
    100100  else
    101101  {
    102     $files = include(PLA_PATH.'_data/'.$_GET['plugin_id'].'.php');
     102    $files = include(PLA_DATA.$_GET['plugin_id'].'.php');
    103103  }
    104104 
  • extensions/plugin_lang_analysis/main.inc.php

    r23427 r23473  
    1616}
    1717
     18global $conf;
    1819
    1920defined('PLA_ID') or define('PLA_ID', basename(dirname(__FILE__)));
    2021define('PLA_PATH' , PHPWG_PLUGINS_PATH . PLA_ID . '/');
    2122define('PLA_ADMIN', get_root_url() . 'admin.php?page=plugin-' . PLA_ID);
     23define('PLA_DATA', $conf['data_location'] . PLA_ID . '/');
    2224
    2325add_event_handler('loc_begin_admin', 'pla_begin_admin');
Note: See TracChangeset for help on using the changeset viewer.