1 Reply Latest reply on Jan 22, 2015 7:26 PM by MW Design

    XML Import Skipping a Tag

    blackbirdwake

      I am trying to set up a set of classified liner ads by importing an xml document of the listings. The problem is, every time I do it skips this certain specific tags. I have tried everything I can think of and can not, for the life of me, figure out why it is skipping these tags. 

       

      This is an example of one of the listings:

      <?xml version="1.0" encoding="UTF-8"?>

      <listings>

        <listing>

          <stock_number>0000000</stock_number>

          <list_price>$18,877</list_price>

          <year>2012</year>

          <make>Honda</make>

          <model>Civic</model>

          <odometer>41,963</odometer>

          <body>Sedan</body>

          <drivetrain>FWD</drivetrain>

          <engine>4 Cyl</engine>

          <transmission>Manual</transmission>

          <exterior_color>Gray</exterior_color>

          <img_src>http://url.org</img_src>

        </listing>

       

      Here is an example of the document setup and ready to accept the XML import:


      Picture 3.png

       

       

      These are the selections I make when I go to import the XML file:


      Picture 4.png

      This is the result I get:

      Picture 5.png

       

       

      If you will notice, it has omitted the year, exterior_color, and body tags (despite the fact that I know those tags are there in the xml document. What am I doing wrong?

        • 1. Re: XML Import Skipping a Tag
          MW Design Level 4

          Sorry I missed this earlier.

           

          ID is rather finicky about the structure in the XML matching the structure of the tags in the template. Make the XML element order match how you want it laid out in the template...or make the template element order match the XML element order.

           

          capture-002582.png

           

          capture-002583.png

           

          I assume a CMS or other database is generating the XML. But even with a spreadsheet as the data source, rearrange the order of the output so that it matches your intended element layout order.

           

          Mike