View Full Version : <input type=file keep the value in php???

06-21-2005, 07:11 PM
Hi ! In my code I show I image. and I want the user to modify the width of the image. First the user choose his image,
<input type=file name='image' onchange='garderImage(image.value)'>
garderImage is a method in javascript for now for I want to keep the value (image.value) to use it in php .... how?? image.value is a javascript code :\\\

06-22-2005, 04:45 PM
Use a hidden input (<input type="hidden" name="cheminALimage"/>) in the same form, and in garderImage() add something like the following:

document.cheminALimage.value = document.image.value;
... then get the value of cheminALimage from your PHP script.