Hi,
I have created the following XML from a Drupal instance and I am using XPath to map the fields. I run the import process which imports all of the nodes into a single node and gives it the title call array. I then get the error below.
This is the XML http://www.propertiesmazarron.es/rss-property-feed.xml
This is the debug from xpath http://pastebin.com/30cBybck
Notice: Array to string conversion in drupal_write_record() (line 7254 of /var/www/spn/includes/common.inc).
Notice: Array to string conversion in drupal_write_record() (line 7254 of /var/www/spn/includes/common.inc).
Warning: Illegal offset type in isset or empty in pathauto_cleanstring() (line 180 of /var/www/spn/sites/all/modules/pathauto/pathauto.inc).
Warning: html_entity_decode() expects parameter 1 to be string, array given in decode_entities() (line 463 of /var/www/spn/includes/unicode.inc).
Warning: Illegal offset type in pathauto_cleanstring() (line 223 of /var/www/spn/sites/all/modules/pathauto/pathauto.inc).
Notice: Array to string conversion in drupal_write_record() (line 7254 of /var/www/spn/includes/common.inc).
I have spent 3days trying to workout what the problem is cannot find the issue.
| Comment | File | Size | Author |
|---|---|---|---|
| #7 | asdd.png | 80.52 KB | janebootydoe |
Comments
Comment #1
janebootydoe commentedDid you find the solution to this? I'm having the same problem with rss.
Comment #2
mambotech commentedUnfortunately no .... I am waiting for a response from the dev. Really need to understand why it is happening with this XML. I have other XML which is working.
Comment #3
janebootydoe commentedWhen you check debug does it list all of the titles correctly? For me it does which is the most confusing part. The parser is doing its job, but the processor is failing somehow.
Comment #4
mambotech commentedYeah in my work XML it works OK with know errors. You may want to check you context paths in the Xpath mapping.
Comment #5
janebootydoe commentedI get no errors too, when I check the debug box it makes a big list of all the titles though. But only creates 1 node titled array. I wonder if it's due to a drupal core update.
http://shaffir1.libsyn.com/rss is the feed I'm testing with, doing /rss for context and channel/item/title for the title.
Comment #6
mambotech commentedThat link is not the raw XML ... I use Views Data Export module to create the XML http://www.propertiesmazarron.es/rss-property-feed.xml
Comment #7
janebootydoe commentedThat's what I'm importing from, not exporting. Common syndication works for everything I need but /rss/channel/title (not /rss/channel/item/title), so I have to use xpath. Which it works for as you can see. It just refuses to make nodes correctly :(
Comment #8
Alex777 commentedI am using the latest version of Feeds xPath Parcer to import the contents (job postings) from xhtml web page to Drupal 7.
Debug shows me that I imported 7 job postings into D7 and says that only 1 node has been created. Indeed I get 1 node instead of 7 nodes. No errors. I tried standalone as well as attached the importer to a node.
I cannot understand where I went wrong.
For RSS news import (with other importers) everything was ok - many nodes were created.
Comment #9
janebootydoe commentedAlex777, are you having success with rss and xpath parser? I'm going to switch to this module I think. https://www.drupal.org/project/feed_import It is more complicated to use than feeds though.
Comment #10
mambotech commentedHi,
I have managed to get the importer working with Feeds Extensible Parsers and it imports all nodes separately but I am still having a problem with importing images.
Comment #11
janebootydoe commentedWhat settings are you using that got it to work?
Comment #12
mambotech commentedHi Jane,
See importer below.
http://pastebin.com/XqnsSre4
Comment #13
janebootydoe commentedHi Mambotech. Where did you put this file? Do you mind sharing a screenshot of your feeds admin config? Very lost with this...
Comment #14
lkrier commentedI was having a very similar issue, and I did finally figure out what my particular problem was. I was setting the context node in the XPath settings too high on the tree. Once I changed that to point to the XML node that needed to create the Drupal node, it worked fine.
Comment #15
twistor commented@janebootydoe, that debug output is not correct.
If you are trying to parse RSS, then you want something like this:
context:
/rss/channel/itemitem_title:
titlefeed_title:
/rss/channel/title@mambotech, what values are you trying to parse out of the XML feed?