I'll probably figure out a work-around by the time I get a response, but it's possible I'm going about this in a non-optimal way anyway, so ...
The deal is I'm using xml to structure and provide meta-data for elements of webpage content. The elements are supposed to be independently usable in different places. So I want to make a standard header, keep it in one spot, and it'll look something like this:
Code:
<element name='header'>
<div>
blah blah blah ... straight html ...
<?php blah blah blah ... ?>
<?element name='someotherelement' ?>
</div>
</element>
The element tags are an xml container. Everything inside the element tags, however, I want to be treated as a literal and
not parsed as XML. After some tranformations (running embedded php, expanding embedded elements ... ) it'll all just be sent to the browser as-is.
I'm using PHP's expat parser and I haven't found a nice way to do that. The parser analyzes all the internal html tags like <b> and <div> ... For now I just want the name of the element to be the dictionary key for the code inside the element. It's looking like it would be easier to just parse the file "by hand" ... with my own string manipulation code. But I'd rather not.
Make any sense at all? Any suggestions?
TIA.
