Hi !
It's me, again :o
I'm actually trying to display only entires that the user's who is connected entered.
Registred users have access to a form, which record their username and name via hidden fields. Below is the code I used and that was posted by Grey Head (thank you again !) on the forum :
Now, I would like to add a page for registred users where they can see what they registred.
Then, I'm trying to adapt the code above but I'm stuck.
I don't know how to use "Conditions" under "Model" tab ; I assume I have to put the equivalent of "WHERE nomComplet = nameOfUser" but I don't find the right syntax.
I also struggle to find how tu use variables in the code ; I assume I also have to use it in "Conditions".
Can you help me with that ?
Thank you very much🙂
It's me, again :o
I'm actually trying to display only entires that the user's who is connected entered.
Registred users have access to a form, which record their username and name via hidden fields. Below is the code I used and that was posted by Grey Head (thank you again !) on the forum :
<?php
if ( isset($form->data['username']) && $form->data['username'] ) {
$username = $form->data['username'];
$name = $form->data['name'];
} else {
$user =& JFactory::getUser();
$username = $user->username;
$name = $user->name;
}
?>
<input type='hidden' name='nomUtilisateur' id='nomUtilisateur' value='<?php echo $username; ?>' />
<input type='hidden' name='nomComplet' id='nomComplet' value='<?php echo $name; ?>' />
Now, I would like to add a page for registred users where they can see what they registred.
Then, I'm trying to adapt the code above but I'm stuck.
I don't know how to use "Conditions" under "Model" tab ; I assume I have to put the equivalent of "WHERE nomComplet = nameOfUser" but I don't find the right syntax.
I also struggle to find how tu use variables in the code ; I assume I also have to use it in "Conditions".
Can you help me with that ?
Thank you very much🙂