OnAfterLogin trigger plugin

15 years 4 months ago #82853 by patpat
OnAfterLogin trigger plugin was created by patpat
Hi,

anybody knows how to use the "onAfterLogin trigger".

I have read in another post that there is a plugin for that.




Thank you in advance

Nothing's left for invention.
Keep your ears and eyes wide open !

Please Log in to join the conversation.

15 years 4 months ago #83183 by patpat
Replied by patpat on topic Re:OnAfterLogin trigger plugin
Hi,
after reading documentation plus internet fora,
i have tryed to place the following script just before Onafterlogin code line (in comprofiler.php Cb1.2rc3 line 1618) :

echo "<script type=\"text/javascript\">
window.open('mysite.com/index2.php?option=com_jpfchat','_blank');
</script>\n";



But ... no effect.
Worse, if i delete "echo" ... i get a parse error '<'.

Help :unsure:

Pat

Nothing's left for invention.
Keep your ears and eyes wide open !

Please Log in to join the conversation.

15 years 4 months ago #83225 by krileon
Replied by krileon on topic Re:OnAfterLogin trigger plugin
OnAfterLogin is used within plugins themselves. There isn't a need to modify the core.

You'll want to create a new plugin then add the following
[code:1]$_PLUGINS->registerFunction( 'onAfterLogin', 'YOURFUNCTION', 'getYOURTAB' );[/code:1]

It is used to trigger a function within the plugin after a user logs in.

You can add your code within this new function.


Kyle (Krileon)
Community Builder Team Member
Before posting on forums: Read FAQ thoroughly + Read our Documentation + Search the forums
CB links: Documentation - Localization - CB Quickstart - CB Paid Subscriptions - Add-Ons - Forge
--
If you are a Professional, Developer, or CB Paid Subscriptions subscriber and have a support issue please always post in your respective support forums for best results!
--
If I've missed your support post with a delay of 3 days or greater and are a Professional, Developer, or CBSubs subscriber please send me a private message with your thread and will reply when possible!
--
Please note I am available Monday - Friday from 8:00 AM CST to 4:00 PM CST. I am away on weekends (Saturday and Sunday) and if I've missed your post on or before a weekend after business hours please wait for the next following business day (Monday) and will get to your issue as soon as possible, thank you.
--
My role here is to provide guidance and assistance. I cannot provide custom code for each custom requirement. Please do not inquire me about custom development.

Please Log in to join the conversation.

15 years 4 months ago #83337 by patpat
Replied by patpat on topic Re:OnAfterLogin trigger plugin
Thank you krileon
i am going to try that.
I presume the plugin i have to create is a CB one.

Cheers

Nothing's left for invention.
Keep your ears and eyes wide open !

Please Log in to join the conversation.

Moderators: beatnantkrileon
Time to create page: 1.328 seconds

Facebook Twitter LinkedIn