Issue

When you serialize your pages as XML using XMLUtil class from Day API like Document document = XMLUtil.createXMLDocument(ticket, handle), you receive the following error:

19 Feb 2008 14:42:42,608 DEBUG com.apps.cq.servlets.XmlWriterServlet:71 -requested page cannot provide a default input source:

Solution

See the class com.day.cq.transform.PageToXML. For example:

File xmlFile = new File("/tmp/page.xml"); PageToXML p2xml = new PageToXML(); p2xml.setBinaryAsLink(true); p2xml.apply(cqReq.getTicket().getPage("/content/designground/en/company"), xmlFile);

Za ta izdelek je bila izdana neprenosljiva licenca za priznanje avtorstva, nekomercialno uporabo in skupno rabo pod enakimi pogoji 3.0  Objav v storitvah Twitter™ in Facebook ne urejajo pogoji pogodbe Creative Commons.

Pravna obvestila   |   Pravilnik o zasebnosti v spletu