Added critical code

Gotta remember I am working with PHP. Which is awesome by the way!