add redirect javascript