tengo un gran problema...que seguro alguien de ustedes me podra ayudar.
tengo un script PHP:
Código PHP :
<?
// Turn off all error reporting
error_reporting(0);
//Get screenshot properties
$w = $_POST['width'];
$h = $_POST['height'];
$filename = $_POST['filename'];
//Create an empty image
$image = imagecreatetruecolor($w, $h);
//Fill the image with white pixels
imagefill($image, 0, 0, 0xFFFFFF);
//Fill the image the image with pixels
for($y = 0; $y < $h; $y++){
$currentRow = explode(",", $_POST['y' . $y]);
for($x = 0; $x < $w; $x++){
$pixel = $currentRow[$x];
if($pixel != ""){
while(strlen($pixel) < 6){
$pixel = "0" . $pixel;
}
$r = hexdec(substr($pixel, 0, 2));
$g = hexdec(substr($pixel, 2, 2));
$b = hexdec(substr($pixel, 4, 2));
$col = imagecolorallocate($image, $r, $g, $b);
imagesetpixel($image, $x, $y, $col);
}
}
}
//Download the image
header("Cache-Control: must-revalidate, post-check=0, pre-check=0");
header('Content-Description: File Transfer');
header("Content-type:image/jpeg");
header('Content-Disposition: attachment; filename='.$filename);
imagejpeg($image, "", 100);
?> EL CUAL ME GUSRDA UNA IMAGEN GENERADA POR EL USUARIO,EL CUAL PUEDE HACER UN DIBUJO Y DESCARGARSELO.
ME GUSTARIA QUE EN VEZ DE DESCARGARLO EN EL HEADERcomo pone en este escript.me gustaria que el USUARIO pudiera guardar la imagen generada,en un FOLDER, EN UNA WEB
por ejemplo:
www.paginaweb.com/galeria/misdiseños.html
NO EN EL HEADER !!!
POR FAVOR QUE DEBO CAMBIAR O AÑADIR PARA HACER¿?¿?
GRACIAS POR SU TIEMPO!!!
