I know this has been asked many times previously and I have searched through many of the questions here on stack overflow as well as google. I am still having a small issue and I would love any help you guys can offer.
Basically I am trying to grab my image data and send it to my php script via jquery. Once it gets to my php server it will do the uploading and etc. But my question is how can I get the data sent to my php file so I can do my upload function.
var title = $('.title').val();
var imageName = new FormData($('.bugImage'));
alert(imageName);
$.post('classes/bug-class.php', { type: 'add', image: imageName, title: title})
I am not able to use any plugins so I am just looking for a very basic way to send the image data via jquery. Currently went I activate this jquery command I get the error:
Uncaught TypeError: Illegal invocation