Manual:$wgDisableQueryPages

Details
Disable all hook>Special:MyLanguage/Manual:Hooks/wgQueryPages|query pages if   is on, not just some.