Hi,
I have read these instructions http://www.chronoengine.com/faqs/72-ccv5/5208-connectivity-edit-with-chronoforms.html
but I also need to find the user that making the change. I tried this custom code on load event:
and then i used a hidden filed with name malattiaadmin[input_pic] and value malattiaadmin[input_pic] but the field is not updated.
where am I wrong?
Thanks
Christian
I have read these instructions http://www.chronoengine.com/faqs/72-ccv5/5208-connectivity-edit-with-chronoforms.html
but I also need to find the user that making the change. I tried this custom code on load event:
<?php
$user =& JFactory::getUser();
$name = '';
$email = '';
if ( $user->id > 0 ) {
$name = $user->name;
$groups = $user->get('groups');
};
foreach($groups as $group);
$form->data['malttiaadmin[input_pic]'] = $name;
?>
and then i used a hidden filed with name malattiaadmin[input_pic] and value malattiaadmin[input_pic] but the field is not updated.
where am I wrong?
Thanks
Christian
Hi Christian,
Your PHP is a bit buggy, particularly the last couple of lines - but I'm not sure that you need any info about groups???
What information do you actually need here? If you want to save it in the database then ChronoForms automatically adds the user id to the modified_by column for you (if the column exists).
Bob
Your PHP is a bit buggy, particularly the last couple of lines - but I'm not sure that you need any info about groups???
What information do you actually need here? If you want to save it in the database then ChronoForms automatically adds the user id to the modified_by column for you (if the column exists).
Bob
Hi Bob,
I need to find the name and not the id, and update the colum inpu_pic.
It's possible?
Thanks
Christian
I need to find the name and not the id, and update the colum inpu_pic.
It's possible?
Thanks
Christian
This topic is locked and no more replies can be posted.