madhukar_garg Posted May 24, 2007 Share Posted May 24, 2007 Dear All, Can any one tell me if it is possible to change in language of the complete website by clicking on just the flag of different country. i have seen it in many website. Thanks in Advance madhukar Garg Quote Link to comment https://forums.phpfreaks.com/topic/52792-change-in-language-of-a-website/ Share on other sites More sharing options...
taith Posted May 24, 2007 Share Posted May 24, 2007 basically, you click the flag, it redirect to a page where it sets a cookie for the lanugage... then, you have a default language file selected, and if theres a cookie found, it uses that language file instead... $_COOKIE[lang].'.php'; in that file, you either $variable all your text, or define() them :-) Quote Link to comment https://forums.phpfreaks.com/topic/52792-change-in-language-of-a-website/#findComment-260628 Share on other sites More sharing options...
madhukar_garg Posted May 24, 2007 Author Share Posted May 24, 2007 Hi Taith, Thanks for reply.. You wanna say that first i have change whole contents manually and then to store whole content of the site into that cookie value? please clearify me..... thanks Madhukar Garg Quote Link to comment https://forums.phpfreaks.com/topic/52792-change-in-language-of-a-website/#findComment-260635 Share on other sites More sharing options...
taith Posted May 24, 2007 Share Posted May 24, 2007 not exactly... the cookie is just an access point to the file which contains all of your defined languaged text... Quote Link to comment https://forums.phpfreaks.com/topic/52792-change-in-language-of-a-website/#findComment-260636 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.