[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Noalyss-commit] [noalyss] 03/04: Task #1044 - Implementation de Test
From: |
Dany De Bontridder |
Subject: |
[Noalyss-commit] [noalyss] 03/04: Task #1044 - Implementation de Test |
Date: |
Sun, 30 Nov 2014 12:04:21 +0000 |
sparkyx pushed a commit to branch master
in repository noalyss.
commit b3098d084b5de5ed9da5a09d5ecb212e3a673618
Author: Dany De Bontridder <address@hidden>
Date: Sun Nov 30 13:02:43 2014 +0100
Task #1044 - Implementation de Test
---
html/ajax.php | 20 +++++++++++++++++++-
1 files changed, 19 insertions(+), 1 deletions(-)
diff --git a/html/ajax.php b/html/ajax.php
index c56485e..cbf18a0 100644
--- a/html/ajax.php
+++ b/html/ajax.php
@@ -11,7 +11,7 @@
* - gDossier
* - plugin_code
*/
-define ('ALLOWED',1);
+if ( ! defined ('ALLOWED') ) define ('ALLOWED',1);
require_once '../include/constant.php';
require_once('class_database.php');
require_once('class_user.php');
@@ -30,6 +30,24 @@ $g_user->check(true);
/* if a code has been asked */
if (isset($_REQUEST['plugin_code']) )
{
+ if ( LOGINPUT)
+ {
+
$file_loginput=fopen($_ENV['TMP'].'/scenario-'.$_SERVER['REQUEST_TIME'].'.php','a+');
+ fwrite ($file_loginput,"<?php \n");
+ fwrite
($file_loginput,'//@description:'.$_REQUEST['plugin_code']."\n");
+ fwrite($file_loginput, '$_GET='.var_export($_GET,true));
+ fwrite($file_loginput,";\n");
+ fwrite($file_loginput, '$_POST='.var_export($_POST,true));
+ fwrite($file_loginput,";\n");
+ fwrite($file_loginput, '$_POST[\'gDossier\']=$gDossierLogInput;');
+ fwrite($file_loginput,"\n");
+ fwrite($file_loginput, '$_GET[\'gDossier\']=$gDossierLogInput;');
+ fwrite($file_loginput,"\n");
+ fwrite($file_loginput,' $_REQUEST=array_merge($_GET,$_POST);');
+ fwrite($file_loginput,"\n");
+ fwrite($file_loginput,"include '".basename(__FILE__)."';\n");
+ fclose($file_loginput);
+ }
$ext=new Extension($cn);