BaseX outputting php segments as comment nodes.
Friday, 21 November 2014 · 6 messages · last reply 25 Nov 2014
CG
Hi France,
Once again, I only tried the latest snapshot. This is what I get:
Quoted text · France Baril · 1 line
> curl "http://localhost:8984/cms/ehtml2html5"
<!DOCTYPE html>
<body>
<?php include 'footer/index.html'; >
</body>Could you try and see if using 8.0 makes a difference?
Thanks,
Christian
Quoted text · France Baril · 36 lines
On Fri, Nov 21, 2014 at 10:49 PM, France Baril <france.baril at architextus.com> wrote: > Hi, > > I am trying to output some html that have php instructions, and the > instructions keep showing as comments. > > For example: <body> > > <?php include 'footer/index.html'; ?> > </body> > > > Show up as: > <body><!--?php include 'footer/index.html';--></body> > > Example: > > declare %rest:path('/cms/ehtml2html5') > %rest:GET > %output:method("html") > %output:html-version("5.0")... > > function xhtmlsrc:view-html5(){ <body> > > <?php include 'footer/index.html'; ?> > > </body>}; > > > What am I missing? > > -- > France Baril > Architecte documentaire / Documentation architect > france.baril at architextus.com
FB
France Baril21 Nov 2014 23:49 #
Hi,
I am trying to output some html that have php instructions, and the instructions keep showing as comments.
For example: <body>
<?php include 'footer/index.html'; ?>
</body>Show up as:
<body><!--?php include 'footer/index.html';--></body>
Example:
*declare* %rest:path('/cms/ehtml2html5')
%rest:GET
%output:method("html")
%output:html-version("5.0")...
*function* *xhtmlsrc:view-html5*(){ <body>
<?php include 'footer/index.html'; ?>
</body>};What am I missing?
--
France Baril
Architecte documentaire / Documentation architect
france.baril at architextus.com
CG
Quoted text · France Baril · 1 line
> It's missing the closing ?. Isn't it?
This is how HTML serialization of processing instructions is defined in spec [1]:
Quoted text · France Baril · 2 lines
"The HTML output method MUST terminate processing instructions with > rather than ?>."
CG
I don't know. I recommend you to ask this question on the
talk at x-query.com mailing-list [1]; you usually get a quick answer.
Best,
Christian
[1] http://x-query.com/mailman/listinfo/talk
Quoted text · France Baril · 24 lines
On Tue, Nov 25, 2014 at 10:38 PM, France Baril <france.baril at architextus.com> wrote: > So what's our option for including php that needs the closing '?'? > > On Tue, Nov 25, 2014 at 3:11 PM, Christian Grün <christian.gruen at gmail.com> > wrote: >> >> > It's missing the closing ?. Isn't it? >> >> This is how HTML serialization of processing instructions is defined >> in spec [1]: >> >> "The HTML output method MUST terminate processing instructions with >> > rather than ?>." >> >> [1] http://www.w3.org/TR/xslt-xquery-serialization-31/#HTML_CHARDATA > > > > > -- > France Baril > Architecte documentaire / Documentation architect > france.baril at architextus.com
FB
It's missing the closing ?. Isn't it?
That's what I get on export.
Quoted text · Christian Grün · 56 lines
On Fri, Nov 21, 2014 at 4:07 PM, Christian Grün <christian.gruen at gmail.com> wrote: > Hi France, > > Once again, I only tried the latest snapshot. This is what I get: > > > curl "http://localhost:8984/cms/ehtml2html5" > > <!DOCTYPE html> > <body> > <?php include 'footer/index.html'; > > </body> > > Could you try and see if using 8.0 makes a difference? > > Thanks, > Christian > > > On Fri, Nov 21, 2014 at 10:49 PM, France Baril > <france.baril at architextus.com> wrote: > > Hi, > > > > I am trying to output some html that have php instructions, and the > > instructions keep showing as comments. > > > > For example: <body> > > > > <?php include 'footer/index.html'; ?> > > </body> > > > > > > Show up as: > > <body><!--?php include 'footer/index.html';--></body> > > > > Example: > > > > declare %rest:path('/cms/ehtml2html5') > > %rest:GET > > %output:method("html") > > %output:html-version("5.0")... > > > > function xhtmlsrc:view-html5(){ <body> > > > > <?php include 'footer/index.html'; ?> > > > > </body>}; > > > > > > What am I missing? > > > > -- > > France Baril > > Architecte documentaire / Documentation architect > > france.baril at architextus.com >
--
France Baril
Architecte documentaire / Documentation architect
france.baril at architextus.com
FB
So what's our option for including php that needs the closing '?'?
Quoted text · Christian Grün · 12 lines
On Tue, Nov 25, 2014 at 3:11 PM, Christian Grün <christian.gruen at gmail.com> wrote: > > It's missing the closing ?. Isn't it? > > This is how HTML serialization of processing instructions is defined > in spec [1]: > > "The HTML output method MUST terminate processing instructions with > > rather than ?>." > > [1] http://www.w3.org/TR/xslt-xquery-serialization-31/#HTML_CHARDATA >
--
France Baril
Architecte documentaire / Documentation architect
france.baril at architextus.com
Written for BaseX 7.9. BaseX may have changed since: please check the current documentation.
⚡Generated with XQuery