I recently came through some Drupal apps that I needed to send some silent Ajax requests that performs a database update, and nothing else. Every such requests bootstraps Drupal to its full level which, as far as I can see, is a waste of resources.

Where I can find examples that someone would bootstrap Drupal, but not to its full level?

One example is the statistics module in core. ./modules/statistics/statistics.php. Do you know any others?

Please note this question is not about "how to bootstrap". Rather, in trying to see some examples of applications of it.

Thanks, and hats off everyone in advance.


The JS module is specifically for this. It allows you to create ajax callback that only bootstrap to a level you specify via a hook_js().

So you could either use this module or take a look at its code to see how it works.

Good blog post about it HERE

  • Awesome. This blog post is really helpful. I think I overlooked JS module too. Thanks a lot for this! – AKS Dec 17 '14 at 1:37

I think the best place to start answering your question its to look at Drupal's own boostrap implementation.


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.