--- a/web/event_process.php Wed Nov 27 13:03:08 2013 +0100
+++ b/web/event_process.php Wed Nov 27 13:21:24 2013 +0100
@@ -15,12 +15,21 @@
}
$config_content = "<?php\n\$config = array(\n";
foreach ($config_values as $key => $value) {
- $config_content .= " '$key' => '$value',\n";
+ if($value === "__TRUE__") {
+ $config_content .= " '$key' => true,\n";
+ }
+ elseif ($value === "__FALSE__") {
+ $config_content .= " '$key' => false,\n";
+ }
+ else {
+ $config_content .= " '$key' => \"".addslashes($value)."\",\n";
+ }
}
$config_content .= ");\n";
$zip->addEmptyDir($event_title);
- $zip->addFromString("$zip_folder/config.php", $config_content);
+ $zip->addFromString("$event_title/config.php", $config_content);
+ $zip->addFromString("$event_title/index.php", "<?php\n// Permanent redirection\n\nheader(\"HTTP/1.1 301 Moved Permanently\");\nheader(\"Location: client.php\");\nexit();");
$zip->addEmptyDir("$event_title/images");
foreach ($files as $key => $file_desc) {