[xep-support] Re: line 1: Incorrect top element - should be 'root'

Kevin Brown kevin at renderx.com
Mon Apr 30 13:26:31 PDT 2018


RenderX does not format pure XML. Nothing does unless you just want to print out the tags.

You are sending to it an XML that starts with <article>.

So the error message is correct, what you send to RenderX should start with <fo:root> or at the very least, it should have an XSL stylesheet reference that turns your <article> into an XSL FO document that starts with <fo:root> (like the Docbook XSL stylesheets would).

 

You need to convert your XML to XSL FO or add an XSL stylesheet reference for RenderX to understand what XSL you are using to process your document.

 

Kevin Brown

(650) 327-1000 Direct

(650) 328-8008 Fax

(925) 395-1772 Mobile

skype:kbrown01

 <mailto:kevin at renderx.com> kevin at renderx.com

 <mailto:sales at renderx.com> sales at renderx.com

 <http://www.renderx.com/> http://www.renderx.com 

 

 

 

From: Xep-support [mailto:xep-support-bounces at renderx.com] On Behalf Of Stephen Taylor
Sent: Monday, April 30, 2018 1:06 PM
To: Ron Catterall <ron at catterall.net>
Cc: XEP Support <xep-support at renderx.com>
Subject: [xep-support] Re: line 1: Incorrect top element - should be 'root'

 

Sadly, same result. 

 

Stephen




 

 

Stephen Taylor | Librarian | Kx | +44 7713 400852 | stephen at kx.com <mailto:stephen at kx.com> 

 

On 30 April 2018 at 19:40, Ron Catterall <ron at catterall.net <mailto:ron at catterall.net> > wrote:

try:

  xmlns="http://docbook.org/ns/docbook" version="5.1"  (not 5.0)

is this a name space confusion ?

   docbook-xsl-1.79.2 gets the name space version.

Ron

 

 

On 04/30/2018 01:29 PM, Stephen Taylor wrote:

I'm rendering a PDF from DocBook 5 XML generated by Pandoc from Markdown source.  

 

The Pandoc output begins:

 

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

<!DOCTYPE article>

<article

  xmlns="http://docbook.org/ns/docbook" version="5.0"

  xmlns:xlink="http://www.w3.org/1999/xlink" >

 

XEP aborts with a validation error on the XML, complaining 

 

line 1: Incorrect top element - should be 'root'

 

There is an easy workaround: remove the line:

 

  xmlns="http://docbook.org/ns/docbook" version="5.0"


Looks to me like Pandoc has the right way to declare the namespace; seems strange XEP should choke on it. Is there a better way to correct the problem?

 

 

 

Stephen Taylor | Librarian | Kx | +44 7713 400852 | stephen at kx.com <mailto:stephen at kx.com> 

 

_______________________________________________
(*) To unsubscribe, please visit http://lists.renderx.com/mailman/options/xep-support
(*) By using the Service, you expressly agree to these Terms of Service http://w
ww.renderx.com/terms-of-service.html <http://ww.renderx.com/terms-of-service.html> 





-- 
Ron Catterall
ron at catterall.net <mailto:ron at catterall.net> 

 

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.renderx.com/pipermail/xep-support/attachments/20180430/6ad5151d/attachment.html>


More information about the Xep-support mailing list