first draft up upload func
upload func works