Joomla 5 Notice

We are pleased to announce that as of January 29, 2024, all of our Joomla extensions are compatible with Joomla 5.

For all who are still updateing from Joomla 3 to Joomla 4: Joomla 4 Migration instructions are available here:

There is now a separate Documentation for Visforms for Joomla 4 and for Visforms for Joomla 5!

Forum

Visforms Subscription user can ask questions in our forum. Please log in with the relevant user first.
Everybody can access the forum for reading.

Please only ask 1 question per topic.

Important information for almost every question:
V1: Which Visforms version is running?
V2: Which Joomla version is running?
V3: Which PHP version is running?

Importing data

More
8 years 1 week ago - 8 years 1 week ago #3759 by fede491
Importing data was created by fede491
Hi Aicha,
I'm using Visforms version 3.8.9 and also I’m using the Edit Data in Frontend plugin, but I have two questions:

1) in any forms, I can export the data in csv format, but can I import the data into the form via a csv file?

2) How Can I customize the details view fields? (for example, put two fields in the same row)

Thank you
Last edit: 8 years 1 week ago by fede491.

More
8 years 1 week ago #3761 by Administrator AV
Replied by Administrator AV on topic Importing data
Hi,

importing data is not a feature in Visforms. I do not intend to implement such a feature either. The work flow in Visfosrms is one directional. First a user sends data to you using a form. And that is always the first step (Visforms is a form component :)). Afterwards things can be done with the submitted user inputs. For example they can be exported, so that you can use them somewhere else.

At the moment there exists only one fix layout for the data details views in frontend. It is only customizeable which data (data of which field) are displayed but not how they are displayed. If you want to change that, you have to create an override of the layout file in your template (components/com_visforms/views/visformsdata/detail.php or editdetail.php, depending on if you have a menu item visformsdata or edit data) which requires some coding skills. If you use the content plugin data view, you can maybe achieve something with custom css, because with the plugin the detail view is rendered as a html dl element (plugins/conten/vfdataview/tmpl/list.php). Which requires some advanced knowledge of css. Sorry for that. This part of Visforms will certainly be improved in the future.

Regards,
Aicha

:idea: I recommend you the new and up-to-date documentation for Joomla 4:
docs.joomla-5.visforms.vi-solutions.de/en/docs/
Most of this also applies retrospectively to Joomla 3.
Please only ask 1 question per topic :-).

:idea: Ich empfehle Dir die neue und aktuelle Dokumentation für Joomla 4:
docs.joomla-5.visforms.vi-solutions.de/docs/
Das meiste gilt rückwirkend auch für Joomla 3.
Bitte immer nur 1 Frage pro Thema stellen :-).

More
8 years 1 week ago #3762 by fede491
Replied by fede491 on topic Importing data
I am using the edit data in frontend plugins, I think the file is to be modified: detailedit.php, the part to be changed is this?


<?php } ?>

<?php $k = 0;
$n=count( $this->fields );
for ($i=0; $i < $n; $i++)
{
$rowField = $this->fields[$i];

if (isset($rowField->frontdisplay) && ($rowField->frontdisplay == 1 || $rowField->frontdisplay == 3))
{
$prop="F".$rowField->id;
if (isset($this->item->$prop) == false)
{
$prop=$rowField->name;
}
if (isset($this->item->$prop))
{
$texte = $this->item->$prop;
} else {
$texte = "";
}
?>

<tr>
<td class="visfrontlabel">

<?php echo $rowField->label; ?> :

</td>

More
8 years 1 week ago #3763 by fede491
Replied by fede491 on topic Importing data
I use the edit data in frontend plugins because my web site serves the employees of my company to modify the data entered by other operators, as in an assembly line, but if a form is made up of 150 fields to import data from a file cvs (exported directly from another database) is much faster. I will try to enter data with a query directly in mysql. You could develop this function if you were paying for your work?
Thanks and good job

More
8 years 1 week ago #3767 by Administrator AV
Replied by Administrator AV on topic Importing data
Hi,

this is the correct file.
As you can see, I render the data as a html-table (which starts above the code you mentioned) and where each form field is put into a tr. (There is only one of these tr's in the code you mentioned, there are more). So you might have to change the html completely form table to something else or put more than one field into a tr...
But basically this is the correct place to start with.

About your import problem. Do you need a one time import or is this something which you have to do repeatedly. If the data are already in a database and you only need a one time import, maybe it would be easier to use mysql export to file and import file instead of using a csv-file. and adapt the exported data before you import them.

If this is a task, which you have to perform repeatedly I could write a custom script for you, as paid work. If you import data into Visforms you have to deal with proper id-index, overhead fields like the user, who created the record set must be set properly. To some extend, import data might have to be validated. The amount of time, necessary for the implementation depends on such things (does the import file contain all information, is there some validation to do, do you need to be able to select the import file or can it just be a name/folder convention so that Visforms just uses the file with this name in this folder, do you need other options to control the import,..). So this is certainly not done in 1 or 2 hours but more like a day.

Regards,
Aicha

Regards,
Aicha

:idea: I recommend you the new and up-to-date documentation for Joomla 4:
docs.joomla-5.visforms.vi-solutions.de/en/docs/
Most of this also applies retrospectively to Joomla 3.
Please only ask 1 question per topic :-).

:idea: Ich empfehle Dir die neue und aktuelle Dokumentation für Joomla 4:
docs.joomla-5.visforms.vi-solutions.de/docs/
Das meiste gilt rückwirkend auch für Joomla 3.
Bitte immer nur 1 Frage pro Thema stellen :-).

More
8 years 1 week ago #3768 by fede491
Replied by fede491 on topic Importing data
for my first problem I played a few hours to file detailedit.php, here is the result:



It is what I need, it's not nice but I will do more changes in the next few days.

thanks for your suggestions!!!!

for the second problem.....yes It is a daily task....we can talk about privately?

Moderators: Administrator AVAdministrator IV
Powered by Kunena Forum