Page 1 of 1
more_rewrite issue
Posted: Mon Nov 06, 2006 6:22 am
by itsmani1
reason for the mod_rewrite is that i want to make pages like /xxxx/xxxx.html etc
just new to reguller expressions
tried this:
^([a-zA-Z]+$\[0-9]+$\(.*).html$) viewtickets.php?ContentID=$2
Code: Select all
need rule that can send
/xxxxxx/111111/abc.html to index.php?cid=111111
Posted: Mon Nov 06, 2006 8:27 am
by volka
itsmani1 wrote:tried this:
^([a-zA-Z]+$\[0-9]+$\(.*).html$) viewtickets.php?ContentID=$2
and then what happend?
try to explain your current pattern, e.g.
[0-9]+ matching one or more digit
Posted: Tue Nov 07, 2006 5:24 am
by itsmani1
Code: Select all
^([a-zA-Z]+$\[0-9]+$\(.*).html$) viewtickets.php?ContentID=$2
[a-zA-Z]=> a to z and A to Z
[0-9] => 0 to 9
(.*) => anything will come
.html => ends at .html
Posted: Tue Nov 07, 2006 5:37 am
by timvw
So why do you have + and $ in the expression??
Btw:
.html means: match any character and then the characters 'html'
\.html means: meatch the characters '.html'
Posted: Tue Nov 07, 2006 6:01 am
by volka
timvw wrote:So why do you have + and $ in the expression??
Not only that but all the red parts are not explained.
itsmani1 wrote:
^([a-zA-Z]+$\[0-9]+$\(.*).html$) viewtickets.php?ContentID=$2