$user->uid from outside drupal
Hi, all. in 4.6 it was enough to include bootstrap.inc and common.inc and then check !$user->uid with global $user, but in 4.7 it does not works. How to do it? How to check if the user logged in from popup openned by drupal? Thank you -- Tamir
Take a look at drupal_bootstrap(). I'm not sure if you need to do a full bootstrap, but I don't think it would hurt. See update.php for an example. http://api.drupal.org/api/4.7/function/drupal_bootstrap ~Rob Tamir Khason wrote:
Hi, all.
in 4.6 it was enough to include bootstrap.inc and common.inc and then check !$user->uid with global $user, but in 4.7 it does not works. How to do it? How to check if the user logged in from popup openned by drupal?
Thank you
-- ---------------------------------------------------------- It is by Caffeine alone that I set my mind in motion It is by the beans of Java, that my thoughts acquire speed The hands acquire shakes; the shakes become a warning It is by Caffeine alone that I set my mind in motion
On Sat, 17 Jun 2006 21:43:03 +0200, Robert Wohleb <rob@techsanctuary.com> wrote:
Take a look at drupal_bootstrap(). I'm not sure if you need to do a full bootstrap, but I don't think it would hurt. See update.php for an example.
It will hurt your performance. You want DRUPAL_BOOTSTRAP_SESSION.
http://api.drupal.org/api/4.7/function/drupal_bootstrap
~Rob
Tamir Khason wrote:
Hi, all.
in 4.6 it was enough to include bootstrap.inc and common.inc and then
wow. including bootstrap.inc and common.inc basically loaded all Drupal which is quite a heavy operation...
Take a look at drupal_bootstrap(). I'm not sure if you need to do a full bootstrap, but I don't think it would hurt. See update.php for an example.
It will hurt your performance. You want DRUPAL_BOOTSTRAP_SESSION.
wow. including bootstrap.inc and common.inc basically loaded all Drupal which is quite a heavy operation...
basicly i did it WITHOUT drupal_bootstrap. The only thing I want to know if the user logged in or from outside drupal enviroment (not from index/main.php). -- Tamir
participants (3)
-
Karoly Negyesi -
Robert Wohleb -
Tamir Khason