fixing api with cross site scripting and ability to ask for relative time