Fixed method declaration for PHP 5.5, Added debug query view option