4 This plugin automatically stores global variables into a
5 pages {meta} field, if they is saved after editing.
7 In the following configuration array you can define which variable
8 is to be stored with which name into the {meta} field.
11 #-- which vars to store:
12 $ewiki_config["save_storevars"] = array(
13 # "global_var" => "meta_field_name",
15 # "counter" => "X-Hit-Counter",
20 $ewiki_plugins["edit_save"][] = "ewiki_edit_save_storevars";
24 function ewiki_edit_save_storevars(&$save, &$old_data) {
28 foreach ($ewiki_config["save_storevars"] as $globalname => $metaname) {
29 if ($value = &$GLOBALS[$globalname]) {
30 $save["meta"][$metaname] = $value;