Reformating
Added compability for PHP 5.2 for the redirect support