Hello,
I'm facing a small problems regards WHERE clause in chronoconnectivity
I'm trying to pass the user_id (logged in)...but in the query it show as 'IS NULL'
In the debug of the main form the user_id is detected correctly as you can see in the attachment
The sintax I have used in Models---Conditions is:
where is my mistake?
Thanks for your support!
p-s the user is logged and the id is 429
I'm facing a small problems regards WHERE clause in chronoconnectivity
I'm trying to pass the user_id (logged in)...but in the query it show as 'IS NULL'
In the debug of the main form the user_id is detected correctly as you can see in the attachment
The sintax I have used in Models---Conditions is:
<?php
return array('risultatitest.user_id' => '$form->data['user_id']');
?>
where is my mistake?
Thanks for your support!
p-s the user is logged and the id is 429
Hi sortby,
I suspect that ChronoConnectitivy has no idea about the form data so you have to give it the id. Please try this
Bob
I suspect that ChronoConnectitivy has no idea about the form data so you have to give it the id. Please try this
<?php
$user = \JFactory::getUser();
return array('risultatitest.user_id' => $user->id );
?>
Bob
Hi Bob,
your suspect was right...now it works like a charm!
Many Thanks
p.s. is planned a new CF/CC cookbook V5? 😉
your suspect was right...now it works like a charm!
Many Thanks
p.s. is planned a new CF/CC cookbook V5? 😉
Hi sortby,
Sorry, no plans for a CookBook at present unless some friendly publisher sponsors it. It took about six months to write the last one - and the forum was a lot quieter then.
Bob
Sorry, no plans for a CookBook at present unless some friendly publisher sponsors it. It took about six months to write the last one - and the forum was a lot quieter then.
Bob
OK, got it!
I know it takes a looong time, and wondering about a pdf cookbook to sell directly you?
Just because I think the project is very interesting and is useful to group all the knowledge and information that you and the forum has already generated.
By the way this is my personal plause!
😉
Sortby
I know it takes a looong time, and wondering about a pdf cookbook to sell directly you?
Just because I think the project is very interesting and is useful to group all the knowledge and information that you and the forum has already generated.
By the way this is my personal plause!
😉
Sortby
This topic is locked and no more replies can be posted.