Author Topic: EasySpoiler and WPML  (Read 4081 times)

parared

  • Tadpole
  • *
  • Posts: 5
  • Karma: +0/-0
    • View Profile
EasySpoiler and WPML
« on: July 10, 2013, 03:58:07 PM »
Hello there,

I wonder if there is a possibility to use separate translations for "Show/Hide" Button with EaysSpoiler and WPML-Plugin. If this is helping you, here's some code making the theme I use checking which language is currently used

Code: [Select]
function webtreats_lang_test( $atts, $content = null ) {
    extract(shortcode_atts(array(
        'lang'      => '',
    ), $atts));


$lang_active = ICL_LANGUAGE_CODE;

if($lang == $lang_active){
return do_shortcode($content);
}

   
}
add_shortcode('wpml_translate', 'webtreats_lang_test');

see more: http://mysitemyway.com/docs/index.php/Using_WPML#WPML_shortcode

Thank you for your effort and nice plugin!
« Last Edit: July 10, 2013, 04:30:03 PM by parared »

parared

  • Tadpole
  • *
  • Posts: 5
  • Karma: +0/-0
    • View Profile
Re: EasySpoiler and WPML
« Reply #1 on: August 14, 2013, 02:38:31 PM »
Hello,

I'd really like to see a solution on this. Even some kind of hard-coding would do for me. There must be a way using hooks/filter or so, but I don't get it to dive so deep into the code.

Please help anybody - thank you!

doug@dyerware.com

  • Administrator
  • Sr. Member
  • *****
  • Posts: 456
  • Karma: +15/-0
    • View Profile
    • Email
Re: EasySpoiler and WPML
« Reply #2 on: August 27, 2013, 11:21:10 PM »
I may be able to add this.  You still needing it?

parared

  • Tadpole
  • *
  • Posts: 5
  • Karma: +0/-0
    • View Profile
Re: EasySpoiler and WPML
« Reply #3 on: August 30, 2013, 05:26:34 PM »
I'd love to!

As I said, it must not be a "compatible" modification, just some hardcoding for my case would be fine.

 

anything