Code Comments
Programming Forum and web based access to our favorite programming groups.IS there a way, in code, to SET $_SERVER['HTTP_ACCEPT_LANGUAGE'] Or is it read-only? -Ike
Post Follow-up to this messageIke wrote: > IS there a way, in code, to SET > > $_SERVER['HTTP_ACCEPT_LANGUAGE'] > > Or is it read-only? > > -Ike Why would you want to do that.... Peace, Ryan Heuser
Post Follow-up to this message"Ike" <rxv@hotmail.com> wrote in message news:piBbe.13817$lP1.9430@newsread1.news.pas.earthlink.net... > IS there a way, in code, to SET > > $_SERVER['HTTP_ACCEPT_LANGUAGE'] > > Or is it read-only? > What's the purpouse of doing so? It will not affect the users capability of recieving languages even if you did change it... You can't teach the user a language by setting a variable. For me it would take several years to learn Spanish for example. It's taken me a good 15 years to learn English and I know I still make mistakes. It seems your trying to achieve something else and doing it the wrong way. What is exactly what you were trying to do by setting http_accept_language? -- Welcome to Usenet! Please leave tolerance, understanding and intelligence at the door. They aren't welcome here. eternal piste erection miuku gmail piste com
Post Follow-up to this messageYes, you guys are right. Im reyting to allow the user to specify pages in various languages, but I think I will go the cookie route for that, using as the default, if it exists. Thanks, Ike "Kimmo Laine" <eternal.erectionN05P@Mgmail.com> wrote in message news:kxFbe.11567$Ch3.7632@reader1.news.jippii.net... > "Ike" <rxv@hotmail.com> wrote in message > news:piBbe.13817$lP1.9430@newsread1.news.pas.earthlink.net... > > What's the purpouse of doing so? It will not affect the users capability of > recieving languages even if you did change it... You can't teach the user a > language by setting a variable. For me it would take several years to learn > Spanish for example. It's taken me a good 15 years to learn English and I > know I still make mistakes. > > It seems your trying to achieve something else and doing it the wrong way. > What is exactly what you were trying to do by setting http_accept_language? > > -- > Welcome to Usenet! Please leave tolerance, understanding > and intelligence at the door. They aren't welcome here. > eternal piste erection miuku gmail piste com > >
Post Follow-up to this message"Ike" <rxv@hotmail.com> kirjoitti viestissä:MDJbe.49$BE3.41@newsread2.news.pas.earthlink.net... > Yes, you guys are right. Im reyting to allow the user to specify pages in > various languages, but I think I will go the cookie route for that, using > as > the default, if it exists. Thanks, Ike > Basicly that's the way to do it. You can only use $_SERVER['HTTP_ACCEPT_LANGUAGE'] to detect what languages user supports, but you can't save anything to it. If none of the languages you serve were found in that, then use the default. If you find a match from languages you serve / what languages user supports, then write it to cookie or session. On subsequent pages see what's inside the cookie / session and serve that language, if none, then default. -- "I am pro death penalty. That way people learn their lesson for the next time." -- Britney Spears eternal.erectionN0@5P4Mgmail.com
Post Follow-up to this message
Show a Printable Version
Email This Page to Someone!
Receive updates to this thread
Powered by vBulletin
Copyright 2000-2006 Jelsoft Enterprises Limited.