Last modified: 2008-01-15 04:47:57 UTC
For JavaScript extensions it will often be useful to know if api.php is installed on the wiki whereby the same function may be implemented more efficiently with it and less efficiently without it. Currently it is not possible for a JavaScript extension to know whether api.php is installed without sending an ajax request. But since the results of such a check can't be remembered for views of subsequent wiki pages it would be quite wasteful to use such a method. I propose a variable such as wgEnableAPI which would be set to "true" if api.php is installed and "false" if not. The name of the variable is not terribly important.
We might want to pass wgEnableWriteAPI in a similar fashion.
Fixed in r29757