tweaked script to move url into config