im using an image uploader program
Consult the documentation for the program.
defining the variables in javascript
You arent defining any variables.
The thing is, I have no idea of what you are really trying to do. How does an image uploader program factor into this? Javascript? What Javascript? Javascript is clientside, PHP is serverside.
HTTP_POST_VAR? HTTP_GET_VAR? They dont exist, and never have, unless you have defined them yourself. In the past we used $HTTP_POST_VARS and $HTTP_GET_VARS, but now we use $POST and $GET.
My suggestion is to write and post the smallest and simplest script that demonstrates the problem. This script must be testable by other people, and not depend on some image uploader program or Javascript (unless it is actually a Javascript problem, upon which you should post in the clientside technology forum instead).