Got the redirecting to the correct URLs working