Re: processing-instruction?

Subject: Re: processing-instruction?
From: Chris Maden <crism@xxxxxxx>
Date: Fri, 6 Mar 1998 17:47:47 -0500
[Stig S. Bakken]
> I am trying to customize the modular docbook stylesheets to produce
> HTML with embedded PHP3 code, which is done with <?php ?> processing
> instructions.
> 
> I am trying to replace the document header with the following:
> 
> <?php
> require("shared-manual.inc");
> manualHeader("Section Heading");
> ?>
> 
> However, since processing-instruction is an atomic flow object, I
> can't use the sosofo containing the "Section Heading" data when
> creating the processing instruction.  The PI wants a string for its
> data.  So I need some way of converting the "title" sosofo to a
> string.  Is that possible?

Since you cant (make processing-instruction), do this instead:

(sosofo-append (make formatting-instruction
		     data: "<?php require(\"")
	       (do-something-with-the-required-file)
	       (make formatting-instruction
		     data: "\"); manualHeader(\"")
	       (do-something-with-the-section-heading)
	       (make formatting-instruction
		     data: "\"); ?>"))

HTH,
Chris
-- 
<!NOTATION SGML.Geek PUBLIC "-//Anonymous//NOTATION SGML Geek//EN">
<!ENTITY crism PUBLIC "-//O'Reilly//NONSGML Christopher R. Maden//EN"
"<URL>http://www.oreilly.com/people/staff/crism/ <TEL>+1.617.499.7487
<USMAIL>90 Sherman Street, Cambridge, MA 02140 USA" NDATA SGML.Geek>


 DSSSList info and archive:  http://www.mulberrytech.com/dsssl/dssslist


Current Thread
  • processing-instruction?
    • Stig S. Bakken - from mail1.ability.netby web4.ability.net (8.8.5/8.6.12) with ESMTP id RAA07756Fri, 6 Mar 1998 17:33:43 -0500 (EST)
      • Chris Maden - from mail1.ability.netby web4.ability.net (8.8.5/8.6.12) with ESMTP id RAA07998Fri, 6 Mar 1998 17:44:21 -0500 (EST) <=
      • Paul Prescod - from mail1.ability.netby web4.ability.net (8.8.5/8.6.12) with ESMTP id RAA18779Sun, 8 Mar 1998 17:21:12 -0500 (EST)
      • <Possible follow-ups>
      • Reynolds, Gregg - from mail1.ability.netby web4.ability.net (8.8.5/8.6.12) with ESMTP id RAA08117Fri, 6 Mar 1998 17:46:40 -0500 (EST)