0

When a user logs in, I want to log the user information from the Profile2 module in a separate file.

How can I achieve this?

  • drupalcontrib.org/api/drupal/… You can use _load() hooks and then save it to file or DB perhaps. – GoodSp33d Jul 9 '12 at 9:11
  • i am new to drupal...do i have to write a separate module for this and use _load() hooks? – Cindrella Jul 9 '12 at 9:14
1

The profiles2 docs state:

Thanks to the foundational entity API the module integrates well with Rules as well as Features.

Install the rules module (http://drupal.org/project/rules) and you should be able to access the profile data after he user login event. To log to the system watchdog with rules you need this patch: http://drupal.org/node/1349882#comment-6190164

This does not write to a separate file, but it would be trivial to extract your entries from the watchdog db table using phpMyAdmin.

And finally it does not require any coding.

  • please tell me where should i add this patch. i think its related to drupal 6. i am using drupal 7 – Cindrella Jul 10 '12 at 11:18
  • Look at the header of the issue, it gives you all the information you need. Look at the version tab of the module to find the right git commands to apply the patch. – BetaRide Jul 10 '12 at 12:03

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.