<?xml version="1.0" encoding="UTF-8"?>
<config>
- <version>1.1.4</version>
+ <version>1.1.5</version>
<params>
<parent>parent</parent>
return "Publication de sources musicales";
}
+ function loaded($env){
+ $AUTO_ACTIVATE = false;
+ if(!$env->bdd("sgbd") || ($plugin_data = $env->plugin_data("mw_sourceml")) === false) return;
+ if(!isset($plugin_data["installed"]) || !$plugin_data["installed"]){
+ $data = $env->data();
+ $sgbd = $data->sgbd();
+ if($env->bdd("sgbd") == "xml"){
+ $AUTO_ACTIVATE = $sgbd->data_exists("sources");
+ }
+ else{
+ $AUTO_ACTIVATE = $sgbd->table_exists("#--sources");
+ }
+ }
+ if($AUTO_ACTIVATE){
+ if(
+ $env->set_plugin_data(
+ "mw_sourceml",
+ array(
+ "installed" => true,
+ "enabled" => true,
+ "priorite" => 0
+ )
+ )
+ ){
+ $env->init_plugins("ASC", $RELOAD = true);
+ }
+ }
+ }
+
function init($env){
$env->set_link("admin/sourceml", $env->url("admin/sourceml"), "SourceML", 50);