1. garikello
  2. RO CSVI
  3. Saturday, 05 September 2015
  4.  Subscribe via email
Hi,

I need XML file exported with Virtuemart product information and some static additional fields.
I tried to use the tutorials, which I found on the webpage. I guess those are too old, because configuration options on CSVI are different than described in tutorials.

No idea how to configure this. It seems that I can find all the fields needed, meaning, those are there to pick. I can't get the idea how get the specific order of the fields in xml file, also, how to get additional fields with static info.

The end result I need is this:

<?xml version="1.0" encoding="utf-8" ?>
<root>
<item>
<name>Nokia 6120</name>
<link>http://www.shop-name.lv/info/Nokia6120/</link>
<price>150.55</price>
<image>http://www.shop-name.lv/images/Nokia6120.jpg</image>
<category_full>Mobilie telefoni >> Nokia</category_full>
<category_link>http://www.shop-name.lv/nokia</category_link>
<manufacturer>Nokia</manufacturer>
<model>6120</model>
<in_stock>7</in_stock> <!-- Preču skaits, kas pieejams piegādei Rīgā 3 dienu laikā. Neobligāts. Skaitliska vērtība. Jāuzrādās arī veikala lapā -->
<delivery_cost_riga>2.99</delivery_cost_riga> <!-- Maksimālā piegādes cena uz adresi Rīgā. Neobligāts. Skaitliska vērtība. -->
<delivery_latvija>5.99</delivery_latvija> <!-- Maksimālā piegādes cena uz adresi Latvijā. Neobligāts. Skaitliska vērtība. -->
<delivery_latvijas_pasts>1</delivery_latvijas_pasts> <!-- Piegāde uz Latvijas pasta nodaļu. Neobligāts. Skaitliska vērtība. -->
<delivery_dpd_paku_bode>0</delivery_dpd_paku_bode> <!-- Piegāde uz DPD Paku Bodes punktiem. Neobligāts. Skaitliska vērtība. -->
<delivery_pasta_stacija>0</delivery_pasta_stacija> <!-- Piegāde uz Pasta Stacijas punktiem. Neobligāts. Skaitliska vērtība. -->
<delivery_omniva></delivery_omniva> <!-- Piegāde uz Omniva punktiem. Neobligāts. Skaitliska vērtība. -->
<delivery_statoil>1.50</delivery_statoil> <!-- Piegāde uz Statoil degvielas stacijām. Neobligāts. Skaitliska vērtība. -->
<delivery_days_riga>4</delivery_days_riga> <!-- Maksimālais darba dienu skaits preces piegādei Rīgā. Neobligāts. Skaitliska vērtība. -->
<delivery_days_latvija>6</delivery_days_latvija> <!-- Maksimālais darba dienu skaits preces piegādei Latvijā. Neobligāts. Skaitliska vērtība. -->
<used>0</used> <!-- Lietotām precēm jānorāda vērtība: 1. Neobligāts. Skaitliska vērtība. -->

</item>
<item>
...
</item>
</root>


Delivery values are set as static values, which are not found in the database.

Step by step short guide, how to accomplish this, would be great.

Thanks.

I have CSVI version 6.0.1
Accepted Answer Pending Moderation
Hello,

No idea how to configure this.
Then you can look at the Process XML files tutorial at the section Custom XML that explains how to setup the XML areas in your export template.

how to get additional fields with static info.
Those you just hardcode into your template. So instead of doing something like
<code>[product_sku]</code>
you do
<delivery_days_latvija>6</delivery_days_latvija>


Check the tutorial and let me know how it goes.
Kind regards,

RolandD

=========================
If you use our extensions, please post a rating and a review at the Joomla! Extension Directory
  1. more than a month ago
  2. RO CSVI
  3. # 1
Accepted Answer Pending Moderation
Ok, it looks the correct tutorial :)

Before I try to set it up, one question:
In the demanded structure I have tags which differ from the column names in the database. For example
<link>http://www.shop-name.lv/info/Nokia6120/</link>

I have a field in VM product_url. So, how do I configure this in XML setup?
which is correct?:
<product_url><\product_url>
or
<link>product_url</link>

NEVERMIND, I found the answer. I will let you know, how it goes.
  1. more than a month ago
  2. RO CSVI
  3. # 2
Accepted Answer Pending Moderation
Just saying you found the answer is not so helpful for the next reader, so the answer is
<link>[product_url]</link>
:)
Kind regards,

RolandD

=========================
If you use our extensions, please post a rating and a review at the Joomla! Extension Directory
  1. more than a month ago
  2. RO CSVI
  3. # 3
Accepted Answer Pending Moderation
Well, It didn't go as planned. Internal error 500...

No idea what wen wrong. I added a log file.
I am runnig this on localhost.
Attachments (1)
  1. more than a month ago
  2. RO CSVI
  3. # 4
Accepted Answer Pending Moderation
Which 500 error do you get? There are 2 different ones, Joomla or the server but I am going to assume it is the server.

I am runnig this on localhost.
You will need to check the server error log for the real error. The 500 error is documented in the 500 Internal server error documentation.

The log file is empty because the server killed CSVI :)
Kind regards,

RolandD

=========================
If you use our extensions, please post a rating and a review at the Joomla! Extension Directory
  1. more than a month ago
  2. RO CSVI
  3. # 5
Accepted Answer Pending Moderation
I tried to run the same tutorial on the host server, I get internal error message as well.

The log has this:

[Sat Sep 19 01:28:59 2015] [error] [client 81.198.30.14] File does not exist: /home/datevlv/public_html/http://lynxgear.lv/404.shtml
[Sat Sep 19 01:28:59 2015] [error] [client 81.198.30.14] File does not exist: /home/datevlv/public_html/http://lynxgear.lv/favicon.ico
[Sat Sep 19 01:28:30 2015] [error] [client 81.198.30.14] File does not exist: /home/datevlv/public_html/http://lynxgear.lv/404.shtml
[Sat Sep 19 01:28:30 2015] [error] [client 81.198.30.14] File does not exist: /home/datevlv/public_html/http://lynxgear.lv/favicon.ico
[Sat Sep 19 01:28:05 2015] [error] [client 81.198.30.14] File does not exist: /home/datevlv/public_html/http://lynxgear.lv/404.shtml
[Sat Sep 19 01:28:05 2015] [error] [client 81.198.30.14] File does not exist: /home/datevlv/public_html/http://lynxgear.lv/favicon.ico
[Sat Sep 19 01:27:52 2015] [error] [client 81.198.30.14] File does not exist: /home/datevlv/public_html/http://lynxgear.lv/404.shtml
[Sat Sep 19 01:27:52 2015] [error] [client 81.198.30.14] File does not exist: /home/datevlv/public_html/http://lynxgear.lv/favicon.ico
[Sat Sep 19 01:27:35 2015] [error] [client 81.198.30.14] File does not exist: /home/datevlv/public_html/http://lynxgear.lv/404.shtml
[Sat Sep 19 01:27:35 2015] [error] [client 81.198.30.14] File does not exist: /home/datevlv/public_html/http://lynxgear.lv/favicon.ico


How favicon file can influence the export?
  1. more than a month ago
  2. RO CSVI
  3. # 6
Accepted Answer Pending Moderation
Hello,

The log you posted is not related to your import. These are only notices about a favicon file not existing. Post an image of your internal server error, so we can see if it is a server or Joomla one. If it is a server one, you may need to contact your host to get the real error.
Kind regards,

RolandD

=========================
If you use our extensions, please post a rating and a review at the Joomla! Extension Directory
  1. more than a month ago
  2. RO CSVI
  3. # 7
Accepted Answer Pending Moderation
Well, I tried to run it once more on live server after reconfiguration of the settings.

I ended up getting xml file without error, but, the file contained the data, where it is shown like this, about three thousand same info:
http://screencast.com/t/HtY986L3

You can see the xml file here, until configuration is corrected: http://new.lynxgear.lv/sal/salidzini.xml
Any ideas what went wrong in configuration?
  1. more than a month ago
  2. RO CSVI
  3. # 8
Accepted Answer Pending Moderation
I ended up getting xml file without error
How did you solve the error?

Any ideas what went wrong in configuration?
You didn't specify how you configured your template but I am going to take a guess. Here is how the first 2 entries must look like
<name>[product_name]</name>
<link>[product_url]</link>
check if you have the [ ] brackets around the field names.
Kind regards,

RolandD

=========================
If you use our extensions, please post a rating and a review at the Joomla! Extension Directory
  1. more than a month ago
  2. RO CSVI
  3. # 9
Accepted Answer Pending Moderation
I didn't solve the error. Provider showed me, how to see internal error (there is a special mode in Cpanel).
I switched the mode on, reconfigured the export task, to be sure, that I didn 't miss anything, and then started to run it.

AND, I missed the brackets....

Also, why there are so many entries. I have only 1500 products, but there are over 3000 entries.

And, should xml file be so big? It is 2 MB.
  1. more than a month ago
  2. RO CSVI
  3. # 10
Accepted Answer Pending Moderation
(there is a special mode in Cpanel).
Would you care to explain? I am interested what that is. Perhaps it can help others since many hosting providers use cPanel.

Also, why there are so many entries. I have only 1500 products, but there are over 3000 entries.
In that case you have duplicates. On the Fields tab, you have a Group By button. Click that and in the popup, select which field you want to group on. I would say you can do the product_sku and that should fix it.

And, should xml file be so big? It is 2 MB.
Depends on what you call big, I don't find 2MB big. This completely depends on your data of course. First see how it goes with only 1500 products.
Kind regards,

RolandD

=========================
If you use our extensions, please post a rating and a review at the Joomla! Extension Directory
  1. more than a month ago
  2. RO CSVI
  3. # 11
Accepted Answer Pending Moderation
Would you care to explain? I am interested what that is. Perhaps it can help others since many hosting providers use cPanel.

Regarding errors, Cpanel offers to switch the PHP version. When you do that, there are settings for each version. Those settings have one option to turn on error showing.

In that case you have duplicates. On the Fields tab, you have a Group By button. Click that and in the popup, select which field you want to group on. I would say you can do the product_sku and that should fix it.


Ok, I will try that one later.

The problem with your extension is that it needs newer PHP version to run, but my old page runs on older PHP version. When I switch server to newer version, old page has errors... since old page is still used for customers, I ca't allow it... so I have some work on late night hours :D

Thanks this far. I will leave feedback, how it goes. It seems that after correction of these mistakes everything should work fine.
  1. more than a month ago
  2. RO CSVI
  3. # 12
Accepted Answer Pending Moderation
Ah yes, the never ending issue of mixing old and new software ;)

Let me know how it goes or if you have any further questions, feel free to ask.
Kind regards,

RolandD

=========================
If you use our extensions, please post a rating and a review at the Joomla! Extension Directory
  1. more than a month ago
  2. RO CSVI
  3. # 13
Accepted Answer Pending Moderation
SO, I managed to have proper xml file, without duplicates.

2 questions:
1) it takes about 35 seconds to generate xml file, is it ok?
2) I read the instructions for making cron job, but it seems that it is suitable for running the tasks in CSVI. Is there any way to schedule tasks in CSVI? I need to create XML file once a day, so it has new products inside.
Perhaps there is an option to save CSVI task as an php file and run it through cron job?

Thanks.
  1. more than a month ago
  2. RO CSVI
  3. # 14
Accepted Answer Pending Moderation
Hello,

2 answers:
  1. That can be perfectly fine, it all depends on the amount of data and which fields you are exporting
  2. You don't schedule the tasks in CSVI, you schedule them in your control panel. I think you have misunderstood the instructions on cron usage. Have a look at this tutorial Setting up a cron job on CSVI 6
Kind regards,

RolandD

=========================
If you use our extensions, please post a rating and a review at the Joomla! Extension Directory
  1. more than a month ago
  2. RO CSVI
  3. # 15
Accepted Answer Pending Moderation
You don't schedule the tasks in CSVI, you schedule them in your control panel. I think you have misunderstood the instructions on cron usage. Have a look at this tutorial Setting up a cron job on CSVI 6


Sorry. Indeed I have read the manual too fast. I guess 3 o'clock in the morning is not the ideal time for work like this.
I will try to make a cronjob using this manual. Will see how it goes.
  1. more than a month ago
  2. RO CSVI
  3. # 16
Accepted Answer Pending Moderation
X-Powered-By: PHP/5.3.29
Set-Cookie: 74c4ed00fee231391d90eea9aeff81f0=0m1b69lc7c471a6soabc6i19a6; path=/; HttpOnly
Content-type: text/html


This is what I get in e-mail after automatic running the cron command and no file generated. What did I miss again?
  1. more than a month ago
  2. RO CSVI
  3. # 17
Accepted Answer Pending Moderation
Not sure what you missed but this only means the cron job started but nothing is actually executed. Did you provide the correct path to the cron job script?
Kind regards,

RolandD

=========================
If you use our extensions, please post a rating and a review at the Joomla! Extension Directory
  1. more than a month ago
  2. RO CSVI
  3. # 18
  • Page :
  • 1


There are no replies made for this post yet.
Be one of the first to reply to this post!