why doesn't this form get submitted once the onchange event is triggered (I thought that it gets triggered once the element is used?)
Try changing the name & id of the 'Submit' button from 'submit'. I imagine that the this.form.submit reference is referring to the input element, not the event method.
that did not help (I probably messed up) but I changed the name of the submit button to upload (When I use the onChange event, It doesn't seem to find the $_POST['upload'] variable
I have this if statement in upload.processor.php
// check the upload form was actually submitted else print the form
or error('the upload form is neaded', $uploadForm);
But seems to see it if the submit button is clicked here
Is that right? why doesnt the event act as if the submit button is clicked?
Let me explain what I'm trying to do as you might have a better way for me to do this...
I'm trying to upload an image the moment the onchange evert is triggered so that the image in thumbnail size appears so that the upload is confirmed to the stupid, also how can this be done without refreshing the page as ill have abnother form on the page I dont want to reset?
Thanks a lot...
I believe that the 'upload' value won't be sent unless you explicitly click the Submit button. I'd put in a hidden input 'form_marker' with a value of the name of the form you're submitting. Then you can check for $POST['formmarker'] == 'form_name' in your PHP code.
Re: the inline submitting, are you avoiding using an existing library for a reason? If you're not adverse to trying an existing script, I'd recommend using http://www.plupload.com/