Page 1 of 1

PHP handling url patterns (keywords: pipeline sitemap xml )

Posted: Thu Oct 02, 2008 7:13 am
by ShotokanTuning
Hi my fellow developers,

I'm used to program using sitemap(s) based on so called pipelines. Where a pattern in the url is used to handle the request in the right way.

Is it possible to use this or similar setup when programming in php?

Code: Select all

 
 
<map:match pattern="articleList">
   <map:generate src="xqueries/articleList.xq" type="xquery"/>
   <map:transform src="stylesheets/articleList.xsl"/>
   <map:call resource="html-layout"/>
</map:match>
 
<map:match pattern="*articles/*.php">
   <map:generate src="articles/{2}.xml" type="xquery"/>
   <map:transform src="stylesheets/article.xsl"/>
   <map:call resource="html-layout"/>
</map:match>
 
 
So for example I have a "article" directory with xml files.

Whenever an address like for example article/article1.php is in the url, I want to take the xml file named "article1.xml" and convert the xml to html by using a xslt or xsl file. And for example article/phpbeginnerhelp.php is in the url, I want to take the xml file named "phpbeginnerhelp.xml" and convert the xml to html by using a xslt or xsl file.

Thanks for helping and explaining. I really appreciate it.

Re: PHP handling url patterns (keywords: pipeline sitemap xml )

Posted: Fri Oct 03, 2008 4:26 am
by ShotokanTuning
Any experts that can point me in the right direction?

Thank you kindly.