quick dirty fix for $this problem @ server and adding access control header