regex - Rewrite engine. How to translate URL -
i new regular expressions , rewrite engine
i want translate: domain.com/type/id
on domain.com/index.php?type=type&id=id
i use rewriterule (\w+)/(\d+)$ ./index.php?id=$1&type=$2
i works fine , able 2 variables website has problem including other files. main url is: http://domain.com/repos/site , after trying type url http://domain.com/repos/site/ee/9, firebug says:
"networkerror: 404 not found - http://domain.com/repos/site/ee/lib/geoext/script/geoext.js"
it seems site takes "ee" part of ulr, not variable.
yes, have change paths. paths behavior:
- href="mypath": append "/mypath" url current url
- href="./mypath": same before
- href="/mypath": append mypath to root. behavior want
note: can use "../" come parent directory of are.
Comments
Post a Comment