Hubs New XML Content Extraction Feature

post date

XML-contentIn today’s blog, I will Introduce 3D Issue Hubs new XML Feature which is ideal for content marketers! Hubs technology has over 18 ways for you to aggregate your online web content. Some methods suit some people better than others. But the platform certainly caters to all marketers who want to communicate with their audiences on all devices and computers and feed their content into auto-updating mobile apps and Hubs.

The XML Feature:
Allow me to use a metaphor to describe an XML doc. Imagine your webpage’s XML document is like a tree structure and with Hubs technology you can choose the branches you like and add those only, this is not possible with or needed with the RSS feed feature. So if you are extracting content from a web source that uses elements you want to avoid then the XML feature is perfect for you.

There are many benefits of using XML:

• You can add a title and if 20 new titles are published that day, then all these articles will automatically feed into your Hub.

• If you are weary of the photos used with each article you can actively choose to not use the image; thus eliminating the element you don’t require.

• It is the same with video and other elements that appear on the original web page, like the “date of publish”; you can pick and choose and have detailed control over the content you want added to the Hub.

digital-publishing

In coding terms the XML document is a raw format file.

The XML parser in the Hubs platform helps to create articles using them.

Imagine you do not want to feed the RSS into your hub, but only want to display a specific part of the feed; then one can use the feed XML file to extract contents from it.

This XML content extraction feature in Hubs allows you to use only the elements you have specified.

In an XML document every element is considered as a node.
For Example: <title lang="en">3D issue</title>
In the above example “title” is called the element node and “3dissue is the text node, lang is a attribute node.
In general anything enclosed between <> are element nodes.
The hubs allows its users to extract the text node of these element node using XPATH.
Below is an example of a XML document

XML-content

As we see from the above document the xml document has an hierarchical structure where <bookstore> is a root node <book> is a child node and <title>,<author>,<year>,<price> being its children nodes to <book> node.
The Xpath Query is used to trace this path and display the text of the element node.
In hubs there are three mandatory node

XML-content

Items field is the path to the parent node whose text node has to displayed
Unique ID is the element node that is unique in the tree structure.
The Title is the node whose text node has to be Extracted.
In the above example if the user decides to extract price element.
Item path /bookstore/book
Unique ID path ./title
Title path ./price
Primary Image is the path to the image element. In this case as we have none we have left it blank
Date/Time ./date
Body ./body

XML-content

The extracted data can now be updated to your hubs.

If you have questions regarding this process please contact us at info@3dissue.com.

By Audrey Henry

 

Copyright © 3D Issue Ltd 2016. All rights reserved.