Hi,
If I want to place a different link on footer.php after line 102 who switch with a WPML language I have an error. Could you tel me wath’s wrong ?
This is the code I would like to add :
<?php if(ICL_LANGUAGE_CODE==’fr’) : ?>
link A
<?php else : ?>
<?php if(ICL_LANGUAGE_CODE==’en’) : ?>
Link B
<?php else : ?>
<?php if(ICL_LANGUAGE_CODE==’nl’) : ?>
Link C
<?php else : ?>
<?php if(ICL_LANGUAGE_CODE==’de’) : ?>
Link D
<?php endif; ?>
I have an error on line 166
<?php } //end nosocket check
Do you have an idea ?
Thank you for your help !
David
Nobody have an idea ? A developer or a person who have facilities with PHP code.
Hey David,
Please try using the code as following
<?php if(ICL_LANGUAGE_CODE=='fr'); ?>
Link A
<?php elseif(ICL_LANGUAGE_CODE=='en'); ?>
Link B
<?php elseif(ICL_LANGUAGE_CODE=='nl'); ?>
Link C
<?php elseif(ICL_LANGUAGE_CODE==''); ?>
Link D
<?php endif; ?>
If that too does not help, please post FTP and WP admin logins here privately so we can look into it.
Best regards,
Yigit
Parse error: syntax error, unexpected ‘elseif’ (T_ELSEIF) in … footer.php on line 107
Could you give me your IP to give your an FTP access ?
Hi,
Please use the code as following
<?php
if(ICL_LANGUAGE_CODE=='fr'){
echo 'Link A';
}
if(ICL_LANGUAGE_CODE=='en'){
echo 'Link B';
}
if(ICL_LANGUAGE_CODE=='nl'){
echo 'Link C';
}
if(ICL_LANGUAGE_CODE=='de'){
echo 'Link D';
}
?>
Tested :)
Best regards,
Yigit
Yes, thank you for your help. Resolved.
Have a nice day !
Hi,
You are welcome! :)
For your information, you can take a look at Enfold documentation here – http://kriesi.at/documentation/enfold/
And if there are features that you wish Enfold had, you can request them and vote the requested ones here – https://kriesi.at/support/enfold-feature-requests/
For any other questions or issues, feel free to start new threads under Enfold sub forum and we will gladly try to help you :)
Best regards,
Yigit