Languages image

i have 2 images:

<?php echo ""; echo ""; ?>

i want if some1 goos to the site the site auto use flag1 as languages…
but if he clicks on flag 2 the languages should change…
and if he clicks flag 1 should go back to the language flag1

and i want to use it in this way:
if flag1 selected echo “Hello”; if flag2 selected echo “Bonjour”;

can some1 help me out here?? thnx a lot

Some basic code for you to start with

[php]<?php
$_SESSION[‘lang’] = ‘lang’;
$lang = ‘en_US’;

if (isset($lang)){
if (@$_GET[‘lang’] == ‘fr_FR’){

?>



<?php echo 'Bonjour'; }else{ ?>




<?php echo 'Hello'; } } $lang = (isset($_GET['lang']) ? $_GET['lang'] : ''); echo '
'; echo $lang; ?>[/php]

if you want to change parts of the content depending on the language selected I’ve got a tutorial that explains step by step how to do that http://daveismyname.com/tutorials/php-tutorials/how-to-create-a-language-changer-with-php/

Sponsor our Newsletter | Privacy Policy | Terms of Service