eZ Community » Forums » Extensions » import images from ezxmltext -sqliimport
expandshrink

import images from ezxmltext -sqliimport

import images from ezxmltext -sqliimport

Friday 29 June 2012 4:41:29 pm - 2 replies

Hi,

I am trying to import images from a 3rd party database  to ez using sqlimport.

I can import the images by providing full path to image , if the content object attibute is of image datatype.

But if I wanted to import from xmltext contain images, I cannot. for example the code below contain images cannot be imported using SQLIXMLInputParser

<Intro>&lt;img height=&quot;75&quot; alt=&quot;&quot; hspace=&quot;8&quot; src=&quot;/UserFiles/Image/115/Viral_thumb.jpg&quot; width=&quot;75&quot; align=&quot;left&quot; vspace=&quot;8&quot; /&gt;&lt;</Intro>

Is there anyway I can do this ?

thanks in advance

Modified on Friday 29 June 2012 4:44:58 pm by Romeo Antony

Monday 02 July 2012 11:33:20 pm

Finally somehow I have managed to import it . I know there is some other perfect solution exists.But I couldn't find it out. My solution as follows

Get the image name and unique id from xmltext

<id>54</id><Intro>&lt;img height=&quot;75&quot; alt=&quot;&quot; hspace=&quot;8&quot; src=&quot;/UserFiles/Image/115/Viral_thumb.jpg&quot; width=&quot;75&quot; align=&quot;left&quot; vspace=&quot;8&quot; /&gt;&lt;</Intro>

create a source handler in sqliimport to import the images as a separate field , for that, images needs to be copied in local directory. Problem is that images cannot be embed as it in external db. It will be mapped into into an  image field within the class object.

 

Modified on Monday 02 July 2012 11:34:53 pm by Romeo Antony

Monday 09 July 2012 9:35:56 am

Finally after little bit customization in bcimportcsv extension, I could export all the articles with lot of embed images within the html content . Exported the images and seperate content object and embeded in article xmltext.

expandshrink

You must be logged in to post messages in this topic!

36 542 Users on board!

Forums menu

Proudly Developed with from