Fixing global variables; local short tags configuration, removing warnings and notices