mod rewrite and urls
Posted: Thu Jan 18, 2007 10:28 am
Im new to creating 'search engine freindly' urls. I am trying to implement the .htaccess method:
<FILES article>
ForceType application/x-httpd-php
</FILES>
I have a link like so: http://www.mysite.com/test/rewrite/article/3/0
Breakdown:
"test" is a directory not a file.
"rewrite" is also a directory not a file.
"article" should be parsed as php.
and '3' and '0' are the values of some parameters.
How do I parse this so it knows to go into directory 'test' then directory 'rewrite' then call article.php and pass the values?
Right now it seems to think that 'test' and 'rewrite' are also values to be passed and not directories. I think....
I guess Im confused as to how to drill down into directories using this method...
My structure:
- rewrite.php lives in the 'test' directory
- article (with no extension) lives in the 'rewrite' directory
- .htaccess also lives in the 'rewrite' directory
Hope this makes sense, any direction would be great!
Thanks in advance
<FILES article>
ForceType application/x-httpd-php
</FILES>
I have a link like so: http://www.mysite.com/test/rewrite/article/3/0
Breakdown:
"test" is a directory not a file.
"rewrite" is also a directory not a file.
"article" should be parsed as php.
and '3' and '0' are the values of some parameters.
How do I parse this so it knows to go into directory 'test' then directory 'rewrite' then call article.php and pass the values?
Right now it seems to think that 'test' and 'rewrite' are also values to be passed and not directories. I think....
I guess Im confused as to how to drill down into directories using this method...
My structure:
- rewrite.php lives in the 'test' directory
- article (with no extension) lives in the 'rewrite' directory
- .htaccess also lives in the 'rewrite' directory
Hope this makes sense, any direction would be great!
Thanks in advance