Pattern Matching

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hello Guys,

I have a question related to pattern matching and wildcards. This is the
scenario.

I have friendly urls on my website. So retrive their path as arguments for
every page.

so for example if I have www.xx.com/contact/me my args array will be

args(
   0 => contact,
   1 => me
)

My requirement is to change the page title on the fly with specific
patterns, so what I do is define a look up table with these columns.

path, pageTitle

contact/me - Contact US

perfect match would be easy because I can exactly look for what I want.

It becomes tricky when I introduce wild cards like contact/* for example. It
could also be contact/me/*

How would I match patterns for this kind of relative matches.? Any ideas
anyone?

Thanks,
V

[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux