testing date without jquery