Posted by frank ralf on December 13, 2017 at 10:10am
It's been quite some time since my last post. Mainly that's because I've been looking at Drupal 8 and how to implement DITA integration with Drupal 8.
Unfortunately, the Import HTML module I've used for importing will not be ported to Drupal 8 any time soon. And the Feeds module, another likely candidate for importing XML, is in a similar state.
But I've just stumbled across the following blog post by Campbell Vertesi about using Migrate which looks quite promissing: "Stop Waiting for Feeds Module: How to Import RSS in Drupal 8"
So stay tuned.
Frank

Comments
Importing an Atom Feed
Based on the above mentioned article and others, Benji Fisher has written an article about using Migrate and Paragraphs for importing an Atom feed:
"Importing an Atom Feed with the Drupal 8 Migrate API and Paragraphs" (Part 1)
Frank
My LinkedIn profile
Sample DITA XHTML migration
Here's a first working example for a migration configuration to import a single XHTML page into Drupal 8.
# Migration configuration
# for importing the XHTML output of the DITA-OT
uuid: 9868abf4-5ab2-48e7-a123-2a6e75875be9
id: dita_xhtml_sample
label: 'DITA XHTML sample migration'
migration_group: default
status: true
source:
plugin: url
data_fetcher_plugin: http
data_parser_plugin: xml
urls: public://changingtheoil.html
item_selector: /html
fields:
-
name: topicid
label: ID
selector: body/@id
-
name: title
label: Title
selector: //h1
-
name: shortdesc
label: Short description
selector: //p[@class='shortdesc']
-
name: taskbody
label: Task body
selector: //div[@class='body taskbody']
ids:
topicid:
type: string
destination:
plugin: entity:node
process:
type:
plugin: default_value
default_value: page
title: title
body/summary: shortdesc
body/value: taskbody
body/format:
plugin: default_value
default_value: 'full_html'
uid:
plugin: default_value
default_value: 1
sticky:
plugin: default_value
default_value: 0
status:
plugin: default_value
default_value: 1
promote:
plugin: default_value
default_value: 0
migration_dependencies:
required: {}
optional: {}
Frank
My LinkedIn profile