Some people have asked about how to embed PHP code and have them interpreted on the fly on their XML pages. There are many different ways to include codes of different scripting languages within web pages.
The following are different ways to include php code within different types of scripting languages, including HTML, SHTML, ASP, PHP, and etc...
============================================
1) This will work for HTML, SHTML, JSP, ASP, and PHP web pages.
<? echo "Hello world!"; ?>
2) This will work for HTML, SHTML, JSP, ASP, and PHP web pages. (basically same as the example 1)
<?php echo "Hello world!"; ?>
3) This will work for ASP pages. (Usually used on MS IIS web servers.)
<% echo "Hello world!"; %>
4) *** This will work with ANY scripting languages. (This may look fimiliar to you, because it's the standard way to include all types of scripting languages within web pages. This way is most often seen on pages which use javascripts. Well, guess what, this will work for XML web pages as well to use PHP coding on the fly.)
<SCRIPT LANGUAGE="PHP"> echo "This works for all scripting languages!"; </SCRIPT>
============================================
Well, hopefully this information will help some of you who are stuck and does not know why the <?php ?> and the <? ?> doesn't work on XML pages. It'll be so much more work to parse XML documents through PHP web pages...hehe...
(btw: i know, you can hardly find any info on embeding PHP codes and have them interpreted on the fly within XML web pages, because I have tried searching on the net! ahhahahha!)
Sincerely Yours.