Forum Moderators: phranque
Options +FollowSymLinks
RewriteEngine on
RewriteRule ^([^/]+)/([^/.]+)/?$ /index.php?act=play&id=$1&cid=$2 [NC,L]
Why is not working?
I also tried:
RewriteRule ^([0-9]*).html$ index.php?act=play&id=$1&cid=$2 [L]
And:
RewriteRule ^(.*)/(.*).html /index.php?act=play&id=$1&cid=$2 [L]
But none working.
/ Jim
These lines work fine, but not the other ones.
RewriteCond %{HTTP_HOST} ^domain\.com
RewriteRule ^(.*)$ [domain.com...] [R=permanent,L]
Thanks in advance.
I just have to get this working:
Options +FollowSymLinks
RewriteEngine on
<Files play>
ForceType application/x-httpd-php
</Files>
But it doesn't take it and I cannot find the reason. Do I have to get my web host to do something?
/ Jim
yoursite.com/file OR
yoursite.com/file/
The second two should work with
yoursite.com/file.html
Also, do you have any other rules or directives in your htaccess or httpd.conf file that may be in conflict or acting on the URL's before they are tested against this rule?
Justin
Skip the first post I made. I got help from another person and he made a full script for me to handle my URLs.
I currently have these:
[domain.com...]
If I get the script to work the URL will be:
[domain.com...]
It is this from the .htaccess that is not working:
<Files play>
ForceType application/x-httpd-php
</Files>
I have no other rules in that nor in the httpd.conf.
The guy who helped me has made a file called play which has a PHP script.
I hope you understand more now, sorry but I am new to this.
You say if the script works the URL will be this:
http://www.domain.com/play/name_of_game
Is the script going to create the URL?
As far as the force application type, don't use this much myself, but here's a couple of things to try: (please, keep in mind /page/ is a directory, not technically a file)
<directory /play>
ForceType application/x-httpd-php
</directory>
<location /play>
ForceType application/x-httpd-php
</location>
Hope this give you some ideas...
Also see: [httpd.apache.org...]
Justin