image upload error wordpress

Images should upload in that format when using wp_handle_upload. It is unclear exactly how you are getting http://localhost/job/?attachment_id=40

I would suggest having something similar to the Handling the File Upload section of this post:

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)