Ok, I re-switch to 5.6 and will keep you up to datekrileon wrote:
Ones with output almost always are obvious in that sense. For example they often contain "Display", "Form", etc.. Some of the older CB triggers are less obvious though, but from here on triggers should be more clear as to what they do and where. If you're unsure if a trigger has output or not you can simply ask and we'll be happy to help or you can dig into the code and find where it's being executed. I understand such documentation would be helpful, but we're a team of 3 with 2 full time. I don't have the time to maintain such documentation. So my time is spent on support and development. One would need to be sacrificed for documentation (that or my entire personal life).Sorry, my bad english : what are the "configuration" of the existing triggers , ie : which ones generates output ( or not ), which ones has the user available ..etc... this is why I think it could be helpfull for everyone.
OK, I understand , no probs
Your enqueueMessage usages should output following the redirect. That's standard Joomla behavior unless your action didn't execute, Joomla cleared the queue, or your template doesn't output message queue. You do not need to build a user object for user data in an action. Just substitute it in. For example [username]. Treat all substitutions, at the very least, as string values. So if you need to assign it to a variable surround it with quotes.Tutorial or other methods found in forum are not working to display CB value ( while I double checked that user is properly logged in )
Anything I'm missing ?
Using the same code in "after user profile save" as exemple works perfectly well. Where is the trick to have the CB maybe loaded / enabled right after login ? sounds it execute before the CB is loaded ? ( as I have normal user available ? )
Same story for the registration, I want to send CB fields just filled-up ( trigger : onaftersaveuserregistration ). Seems I'm missing something in the behavior again of the trigger?
The action is likely executing, but your code maybe erroring (e.g. you've using $application without declaring it then calling a function on it). I can not help you debug your custom code. You can also put your custom code in a PHP file and just do an include in the code action as well if you want a PHP file for it, but you'll lose support for substitutions in your code doing this. If the action isn't executing it's probably failing at the conditions if configured. If an action executed before it does a redirect of any kind then your action also will never execute. The order of your actions on the same trigger is important in that regard.Curl is not executed while some other action before in the PHP are. any restrictions ?
it is an extract of the code, I have appropriate statement for the object creation at the ealier begining of the PHP code. I will dig it out and see then why it is not exectuted. Thanks
Code:// Get a handle to the Joomla application object for debug $application = JFactory::getApplication();
Our current version of Guzzle isn't PHP7 compatible. It has known PHP7 bugs that we can't address yet until CB 2.1 where we'll have to move our minimum PHP requirement to 5.4 to update Guzzle. I recommend PHP 5.6.I tried 5.5, 5.6 and just switched to 7.0. any min requirement ?
Please Log in or Create an account to join the conversation.
You don't need to load anythng. The auto action prepares the user object for you and passed your code through substitutions. Substitution usage information can be found below.Using the same code in "after user profile save" as exemple works perfectly well. Where is the trick to have the CB maybe loaded / enabled right after login ? sounds it execute before the CB is loaded ? ( as I have normal user available ? )
Same story for the registration, I want to send CB fields just filled-up ( trigger : onaftersaveuserregistration ). Seems I'm missing something in the behavior again of the trigger?
I highly suggest setting Triggers to None then execute your action directly to debug it. The URL to execute it directly is under the Global tab of your action. This has output so you can do any kind of debugging you need, check for errors in code, etc..it is an extract of the code, I have appropriate statement for the object creation at the ealier begining of the PHP code. I will dig it out and see then why it is not exectuted. Thanks
Please Log in or Create an account to join the conversation.
I highly suggest setting Triggers to None then execute your action directly to debug it. The URL to execute it directly is under the Global tab of your action. This has output so you can do any kind of debugging you need, check for errors in code, etc..[/quote]it is an extract of the code, I have appropriate statement for the object creation at the ealier begining of the PHP code. I will dig it out and see then why it is not exectuted. Thanks
Please Log in or Create an account to join the conversation.
Please Log in or Create an account to join the conversation.
krileon wrote: Set Triggers to None, login, then execute your action directly. With User set to User substitutions and the user object will be your own. This should allow you to test your code. CB Auto Actions isn't going to just make broken code suddenly work. Your code needs to be functional before you try making CB Auto Actions execute it.
If your action works on profile update, but not on login trigger then you may have condition that's failing or something in your code is dependent on information that's not there. Each trigger offers different variables. So var1 between 2 different triggers can be entirely different for example.
My feedback regarding the little code you have provided is follows.
RE: www.joomlapolis.com/forum/153-professional-member-support/234347-collecting-value-in-cb-action-of-cb-fields?start=6#284600
Global
Triggers: Your Choice
Type: Request
User: User
Access: Everybody
Action
Method: Get
URL:Code:https://xxx.fr/?service_type=session-policy&policy=lioneloney&myemail=[email]
RE: www.joomlapolis.com/forum/153-professional-member-support/234347-collecting-value-in-cb-action-of-cb-fields?limitstart=0#284401
Global
Triggers: Your Choice
Type: Code
User: User
Access: Everybody
Action
Method: Message (Message Queue)
Code:Type: ErrorCode:myusername: [username]
RE: www.joomlapolis.com/forum/153-professional-member-support/234347-collecting-value-in-cb-action-of-cb-fields?start=6#284751
Global
Triggers: Your Choice
Type: Request
User: User
Access: Everybody
Action
Method: Get
URL:Code:https://www.mysite.com/query?toto=34554RF&sessid=[get_referenceid] (no idea where exactly this is coming from, but this will pull from the URL)
I can't really advise you any further. We do not provide support for custom coding. The action it self is working perfectly fine. You need to evaluate your code and ensure your code is working first before trying to use it in CB Auto Actions otherwise debugging it is going to be very difficult.
Please Log in or Create an account to join the conversation.
Please Log in or Create an account to join the conversation.