Hello,
I wanted to ask if it is possible with ChronoForms:
I have in Joomla 2 CF forms.
A CC-login form, when I log in correctly, then I passed (redirect-action) for the 2nd form.
This all works very well.
I wanted to now the 2nd CF-view form a stored image in the database.
I wanted to ask if it is possible with ChronoForms:
I have in Joomla 2 CF forms.
A CC-login form, when I log in correctly, then I passed (redirect-action) for the 2nd form.
This all works very well.
I wanted to now the 2nd CF-view form a stored image in the database.
Hi Fredolino,
I don't understand the question :-(
You can certainly show an image from a name or url saved in the database, if it is the image that is saved as a blob then I'm not so sure.
Bob
I don't understand the question :-(
You can certainly show an image from a name or url saved in the database, if it is the image that is saved as a blob then I'm not so sure.
Bob
Hi Bob,
sorry for the first Topic. This is the full Topic.
I have in Joomla 2 CF forms.
A CC-login form, when I log in correctly, then I passed (redirect-action) for the 2nd form.
This all works very well.
I wanted to now the 2nd CF-view form a stored image in the database.
So I did it:
the 2nd CF Form I in the "Designer" a container of type "DIV" with ID and class
Start code: </ div>
End code: </ div>
In this container, I have a "Costumcode": <p> {params} </ p>
in CF login form I in "Setup" in "On load" a "DB Read-Action", which is to invite the particular image from the database table
On the submit I have an event Switcher Joomla login action. In this action is the "Redirect" link for 2nd form and a "file upload" action. In this action, the image path is stored.
In the "File name code" I have the time this code:
I think that I here "Code Costum" must continue to work with a?
And I can in this code change so that it has a specific image from the database in the 2nd CF-form in "DIV" indicating me -Container?
The login script checks which user category from which logs. Each user belongs to a certain category.
If the user has logged in, the user will see his category-image in the 2nd form.
Best wishes
F.
sorry for the first Topic. This is the full Topic.
I have in Joomla 2 CF forms.
A CC-login form, when I log in correctly, then I passed (redirect-action) for the 2nd form.
This all works very well.
I wanted to now the 2nd CF-view form a stored image in the database.
So I did it:
the 2nd CF Form I in the "Designer" a container of type "DIV" with ID and class
Start code: </ div>
End code: </ div>
In this container, I have a "Costumcode": <p> {params} </ p>
in CF login form I in "Setup" in "On load" a "DB Read-Action", which is to invite the particular image from the database table
On the submit I have an event Switcher Joomla login action. In this action is the "Redirect" link for 2nd form and a "file upload" action. In this action, the image path is stored.
In the "File name code" I have the time this code:
<?php
// Get a db connection.
$db = JFactory::getDbo();
// Create a new query object.
$query = $db->getQuery(true);
$query
->select(array('c.title, c.description, c.params'))
->from($db->quoteName('#__categories', 'c'))
->join('INNER', $db->quoteName('#__alpha_userpoints_coupons', 'a') . ' ON (' . $db->quoteName('a.category') . ' = ' . $db->quoteName('c.id') . ')')
->where($db->quoteName('a.couponcode') . ' = ' . $db->quote($form->data['modAUP_CPsCouponValue'] ));
// Reset the query using our newly populated query object.
$db->setQuery($query);
$db->execute();
// Load the result(1) as an object.
if ($db->getNumRows() > 0)
{
$cat = $db->loadObject();
$params = json_decode($cat->params);
if ($params->image)
{
$form->data['params'] = sprintf('<img src="%1$s" alt="%2$s" />', $params->image, $cat->title);
}
}
?>
I think that I here "Code Costum" must continue to work with a?
And I can in this code change so that it has a specific image from the database in the 2nd CF-form in "DIV" indicating me -Container?
The login script checks which user category from which logs. Each user belongs to a certain category.
If the user has logged in, the user will see his category-image in the 2nd form.
Best wishes
F.
Hi Bob,
sorry for the first Topic. This is the full Topic.
I have in Joomla 2 CF forms.
A CC-login form, when I log in correctly, then I passed (redirect-action) for the 2nd form.
This all works very well.
I wanted to now the 2nd CF-view form a stored image in the database.
So I did it:
the 2nd CF Form I in the "Designer" a container of type "DIV" with ID and class
Start code: </ div>
End code: </ div>
In this container, I have a "Costumcode": <p> {params} </ p>
in CF login form I in "Setup" in "On load" a "DB Read-Action", which is to invite the particular image from the database table
On the submit I have an event Switcher Joomla login action. In this action is the "Redirect" link for 2nd form and a "file upload" action. In this action, the image path is stored.
In the "File name code" I have the time this code:
I think that I here "Code Costum" must continue to work with a?
And I can in this code change so that it has a specific image from the database in the 2nd CF-form in "DIV" indicating me -Container?
The login script checks which user category from which logs. Each user belongs to a certain category.
If the user has logged in, the user will see his category-image in the 2nd form.
Best wishes
F.
sorry for the first Topic. This is the full Topic.
I have in Joomla 2 CF forms.
A CC-login form, when I log in correctly, then I passed (redirect-action) for the 2nd form.
This all works very well.
I wanted to now the 2nd CF-view form a stored image in the database.
So I did it:
the 2nd CF Form I in the "Designer" a container of type "DIV" with ID and class
Start code: </ div>
End code: </ div>
In this container, I have a "Costumcode": <p> {params} </ p>
in CF login form I in "Setup" in "On load" a "DB Read-Action", which is to invite the particular image from the database table
On the submit I have an event Switcher Joomla login action. In this action is the "Redirect" link for 2nd form and a "file upload" action. In this action, the image path is stored.
In the "File name code" I have the time this code:
<?php
// Get a db connection.
$db = JFactory::getDbo();
// Create a new query object.
$query = $db->getQuery(true);
$query
->select(array('c.title, c.description, c.params'))
->from($db->quoteName('#__categories', 'c'))
->join('INNER', $db->quoteName('#__alpha_userpoints_coupons', 'a') . ' ON (' . $db->quoteName('a.category') . ' = ' . $db->quoteName('c.id') . ')')
->where($db->quoteName('a.couponcode') . ' = ' . $db->quote($form->data['modAUP_CPsCouponValue'] ));
// Reset the query using our newly populated query object.
$db->setQuery($query);
$db->execute();
// Load the result(1) as an object.
if ($db->getNumRows() > 0)
{
$cat = $db->loadObject();
$params = json_decode($cat->params);
if ($params->image)
{
$form->data['params'] = sprintf('<img src="%1$s" alt="%2$s" />', $params->image, $cat->title);
}
}
?>
I think that I here "Code Costum" must continue to work with a?
And I can in this code change so that it has a specific image from the database in the 2nd CF-form in "DIV" indicating me -Container?
The login script checks which user category from which logs. Each user belongs to a certain category.
If the user has logged in, the user will see his category-image in the 2nd form.
Best wishes
F.
This topic is locked and no more replies can be posted.