PDA

View Full Version : Get field value from id and post to a form



StefanRSA
09-23-2009, 08:05 PM
I created a function:

function deleteimage1(){
var image1Field = document.getElementById('image1');
upload_field.form.action = 'imagedelete.php';
upload_field.form.target = 'upload_iframe';
upload_field.form.submit();
upload_field.form.action = '';
upload_field.form.target = '';
return true;
}
I am trying to get the value of field with ID 'image1' and then post the value to the imagedelete.php file so I can delete an image without refresh.

This is not working??? Can anybody please help me?