reconfigured method of sending POST to google, isolated mostly to javascript now.