fixing the javascript stuff

services.php still needs to get the gallery back working