Commit 4840a99b authored by Okthane's avatar Okthane

maj

parent ccc05d15
......@@ -64,7 +64,7 @@
previewImage.setAttribute("src", this.result);
});
reader.readAsDataURL(file);
findFaces("img-ID");
//findFaces("img-ID");
}
inpFile.addEventListener("change", function (){
const file = inpFile.files[0];
......@@ -76,7 +76,7 @@
previewImage.setAttribute("src", this.result);
});
reader.readAsDataURL(file);
findFaces("img-ID");
//findFaces("img-ID");
}
});
......
{"errors":[{"title":"No image given","code":"missing_source","detail":"Please provide the source image in the image_url, image_file or image_file_b64 parameter."}]}
\ No newline at end of file
<?php
// phpinfo();
// echo json_encode(array("test"=>"ok")); die;
define('WHERE_TO_PUT','img_bg');
define('PATH_TO_BG', "img_bg");
define('TEMP','temp');
......
......@@ -37,9 +37,12 @@ var format_correct = false;
// SCRIPT ====================================================================================
$(document).ready(function(){
inputFileUpload = $("#"+idFileUpload);
// console.log(inputFileUpload.val());
console.log(getParameter(window.location.href));
//Variables des éléments du DOM.
inputFileUpload = $("#"+idFileUpload);
btnCustomFileUpload = $("#"+idCustomFileUpload);
Img = $("#"+ID);
ImgBG = $("#"+ID_bg);
......@@ -48,7 +51,7 @@ $(document).ready(function(){
Console = $("#"+idConsole);
//empêcher de valider si la photo n'est pas valide
//Si l'on change la photo,
inputFileUpload.change(function(){unSeulVisage=false;format_correct=false});
//Requête pour les vérifications de sécurité & de format
$("#form").on("submit",function (event) {
......@@ -153,13 +156,13 @@ $(document).ready(function(){
})
//Lorsque l'utilisateur souhaite changer d'image
btnCancel.on('click', function(){
unSeulVisage = false;
format_correct = false;
ImgBG.attr('src',"");
Img.attr('src',"");
$("#li-oneface").css('color','black');
});
// btnCancel.on('click', function(){
// unSeulVisage = false;
// format_correct = false;
// ImgBG.attr('src',"");
// Img.attr('src',"");
// $("#li-oneface").css('color','black');
// });
......
......@@ -74,4 +74,4 @@ if($_SERVER["REQUEST_METHOD"] == "POST")
);
echo json_encode($data);
}
?>
\ No newline at end of file
?>
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment