Fix cross site origin to work in all browsers (hopefully)