I´m display a slider that get´s the images from custom field, now I need that the slider shows different images depending on the language (es - ca):
This is the code of the slider:
<a href="<?php the_field('slider_home_1_enlace') ?>">
<img src="<?php the_field('slider_home_1'); ?>">
</a>
So I´m creating a conditional tag to load images depending of the language of qtranslate plugin:
<?php
_e('<!--:es-->
<a href="<?php the_field('slider_home_1_enlace') ?>">
<img src="<?php <the_field('slider_home_1'); ?>">
</a>
<!--:-->
<!--:ca-->
<a href="<?php the_field('slider_home_1_enlace_ca') ?>">
<img src="<?php the_field('slider_home_1_ca'); ?>">
</a>
<!--:-->');
?>
I´m a php begginer so I see the problem maybe that the php is inside another php, because this way its not working, if i just put text between tags it works properly for the language.
Any ideas how to syntax this?