[support] Drupal API - Create user

Daniel Carrera daniel.carrera at zmsl.com
Thu Dec 11 21:15:12 UTC 2008


Earnie Boyd wrote:
>> 3) If I want to make a custom script that uses the Drupal API, which
>> file do I need to include? I can't just include "user.module", clearly
>> that file depends on others.
> 
> You need to include "./includes/bootstrap.inc" and then execute 
> drupal_bootstrap(DRUPAL_BOOTSTRAP_FULL).  The Drupal root directory 
> must be your working directory before doing this.

Ok, thanks. Can I put the program in a different directory and chdir() 
to the Drupal root?

Thanks
Daniel.


More information about the support mailing list