[thelist] SEO and dynamic URL's

sbeam sbeam at syxyz.net
Fri Jul 9 09:39:52 CDT 2004


On Thursday 08 July 2004 05:42 pm, Joshua Olson wrote:
> http://www.houseoffusion.com/cf_lists/message/4/33724/
>
> Using URL rewriting tools, this new URL structure could be used in
> place of the original quite easily with only a single rule... aka 1
> line of code, literally.

ok, curiosity is killing me - what would your one-liner be, may I ask? 
I've tried to parse this kind of thing, what you might call 
"slash-delimited" query strings, but what to do if there is a slash in 
one of the values? backslash-escape it? convert it to a token? 

do something like the following (psuedo-code):

  parms = split('/', HTTP_PATH_INFO);
  for (i=0; i<count(parms); i+=2) {
    QUERY_PARAMS[parms[i]] = parms[i+1]
  }

add in special acrobatics to deal with the escaped slashes and its a lot 
more than one line...?

-- 

# S Beam - Web App Dev Servs
# http://www.onsetcorps.net/


More information about the thelist mailing list