Hello,
I searched in the forum, but I cannot find any good solutions (V7). How can I do this?
I tried use this, but no success: https://www.chronoengine.com/faqs/cfv4/cfv4-working-with-the-database/how-can-i-edit-the-record-for-an-image
When I want to use in HTML field any PHP tag, simply write out this code without use PHP.
Any better idea?
Thanks!
Balazs
I searched in the forum, but I cannot find any good solutions (V7). How can I do this?
I tried use this, but no success: https://www.chronoengine.com/faqs/cfv4/cfv4-working-with-the-database/how-can-i-edit-the-record-for-an-image
When I want to use in HTML field any PHP tag, simply write out this code without use PHP.
Any better idea?
Thanks!
Balazs
I found a solution.
Before saving data to database, I create a PHP field with this:
$photo = $this->data('fnykp_az_zletrl');
$photo_old = $this->data('rejtett_kp');
if (!$photo)
{
$new_photo = $photo_old;
} else
{
$new_photo = $photo;
}
return $new_photo;
Then in data saving use this output and it is work!
Before saving data to database, I create a PHP field with this:
$photo = $this->data('fnykp_az_zletrl');
$photo_old = $this->data('rejtett_kp');
if (!$photo)
{
$new_photo = $photo_old;
} else
{
$new_photo = $photo;
}
return $new_photo;
Then in data saving use this output and it is work!
You need to login to be able to post a reply.