0

I am using a (dv) server from Media Temple, and I have wordpress installed on the root of my domain.

I have a directory called support that holds a standard xhtml webpage, but if the user enters the domain name as follows:

www.domain.com/directory

the wordpress page not found shows up, however, if the user enters:

www.domain.com/directory/

the xhtml page shows up.

Is it possible to force the server to direct anyone who types /directory to /directory/?

Sorry if this isn't making much sense!

Thanks,

Danny

dannymcc
  • 2,677
  • 10
  • 46
  • 72

2 Answers2

0

If this is a Linux server it should happen anyway as you can't have a file and a directory in the same place with the same name - I'd guess that the request is being rewritten so maybe your .htaccess file would help here.

Aside from that, the following in your .htaccess should do it:
RewriteEngine On
RewriteRule ^directory$ directory/

or
Alias /directory /directory/

James L
  • 5,915
  • 1
  • 19
  • 24
0

the behaviour you are asking for is the DEFAULT in any sane server for good reasons...

assuming it's apache, maybe your hoster disabled THIS? http://httpd.apache.org/docs/2.0/mod/mod_dir.html#directoryslash (it would be a really bad idea to do that globally on a shared hosting server, if it's the case, do complain about it...)

also read that entry to understand WHY that behaviour is the default...

r00t
  • 321
  • 1
  • 2
  • actually, most likely it's due to some rewriterule(s) in your htaccess file for wordpress that overrides the default behaviour... usually you would have a rule in there that passes requests for existing files to the default handling... – r00t Dec 20 '10 at 19:17