fix urls and now upload uses a temp dir