fix StaticController to be compatible with php < 5.4 version