Page 1 of 1

How to batch import article from xls to KB?

Posted: Mon Sep 02, 2013 7:30 am
by deserteagle369
Script URL:
Version of script: 2.3
Hosting company:
URL of phpinfo.php:
URL of session_test.php:
What terms did you try when SEARCHING for a solution:

Write your message below:
I have over thousand articles in xls/csv format with only text in subject and content, no html tag, the problem is when I import it to hesk_kb_articlws table by phpmyadmin, there is no html tag for the contents, so the contents is in one row, the url is not linkable, how to markup it?

Re: How to batch import article from xls to KB?

Posted: Mon Sep 02, 2013 2:19 pm
by Klemen
You would need a custom script written for something like this (read file, convert to HTML, connect to HESK database and insert using proper field values). Not something I can help with unfortunately.

Re: How to batch import article from xls to KB?

Posted: Wed Sep 04, 2013 3:33 am
by deserteagle369
Finally I find a solution for this, not perfect but it works.

After the xls for import is ready, copy the "content" column to word and replace all manual line break with space, then copy all the contents to the markdownpad (mark down software, free), theck the automatic line break and automatic hpyerlink in the option, then export the html, you can get the contents with html tag by view the source. then copy back to the "content" column in excel.

beware that it's not perfect, you need search <p> or </p> to find mis-tagged place which should be <br />, correct it manually make sure the number of contents match your original one.

the "type","html" and "sticky" are enum field need to be fill with "1","2" and "1" by default.

Re: How to batch import article from xls to KB?

Posted: Wed Sep 04, 2013 2:41 pm
by Klemen
Thanks for sharing your solution.