got js to server working