| Guest |
|
|
Posted: Wed Oct 13, 2004 8:30 am Post subject: Content Negotiation |
| |
Can you tell me if you support full content negotiation, on PHP files too?
I've been through a few hosts and they can't do it! Titan doesn't run Apache and can't do it. One & One run Apache 1.3 but won't tell me what to do in .htaccess to turn it on! All examples I've found by Googling only seem to work with Apache 2 (seemingly all that needs to be done in .htacess is to turn MultiViews on and insert an AddType declaration for PHP)
What I want to be able to do is to call a URL *without* a file extension.
For example http://www.domain.org.uk/file
And the server will find and return a page called file.php if it exists, otherwise file.html.
I also want to be able to do language negotiation so if I call up a file with a URL like the above, the server will arbitrate between files called
file.php.en
file.html.en
file.php.cy
file.html.cy
(I know how to set up the cy language in .htaccess if you haven't go t it by default) |
|
| Back to top |
|
| NetHosted - Andrew |
|
NetHosted Staff

Joined: 22 Mar 2004 Posts: 5684
|
Posted: Wed Oct 13, 2004 11:40 am Post subject: |
| |
I'm afraid we don't support what you are after.
Andrew _________________ | Andrew Bassett
| Managing Director, NetHosted Ltd.
| Resellers, take a look at overselling !
| Members, tell us what you think of NetHosted! |
|
| Back to top |
|
| Guest |
|
|
Posted: Tue Nov 02, 2004 7:21 am Post subject: Re: Content Negotiation |
| |
| Anonymous wrote: |
Can you tell me if you support full content negotiation, on PHP files too?
|
Are you still looking for this feature? |
|
| Back to top |
|
| Guest |
|
|
Posted: Thu Nov 04, 2004 2:58 pm Post subject: Re: Content Negotiation |
| |
| Anonymous wrote: |
Are you still looking for this feature? |
Yes! |
|
| Back to top |
|
| Seedybee |
|
Guest
|
Posted: Fri Mar 11, 2005 12:28 pm Post subject: Re: Content Negotiation |
| |
just a thought for a workaround...
You can call a file without an extension by naming it the servers default name (usually index.html or index.php etc) and then putting it in a folder of the name you want eg: browsing to http://www.yourname.com/file will return http://www.yourname.com/file/index.php
Then couldn't language negotiation be done within your php script eg. having a index.php file that checks language then includes either en.php or cy.php depending on detected language.
There's a php language detection script that should help at: http://techpatterns.com/downloads/php_language_detection.php  |
|
| Back to top |
|
| NetHosted - Mark |
|
NetHosted Staff

Joined: 21 Dec 2004 Posts: 217
|
Posted: Sun Mar 13, 2005 9:38 pm Post subject: |
| |
That would work. there are PHP variables that will tell you the client preferred language and you can then use the PHP header('Location: /index.php.<user_language>'); to redirect the user. _________________ | Mark
| Customer Service & Sales, NetHosted Ltd
| Resellers, take a look at overselling !
| Members, tell us what you think of NetHosted! |
|
| Back to top |
|
| Guest |
|
|
Posted: Fri May 20, 2005 4:46 pm Post subject: |
| |
Very good.  |
|
| Back to top |
|
|
|
User Permissions |
You can post new topics in this forum You can reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum You cannot attach files in this forum You can download files in this forum
|
|
|