• Plugin Author Azizul Hasan

    (@hasanazizul)


    Text To Audio/ Text to speech plugin gives users to change the button text according to users’ locale language. Here is the process. Add attributes to the shortcode. Here is the way:

    [tta_listen_btn listen_text=”Listen” pause_text=”Pause” resume_text=”Resume” replay_text=”Replay” start_text=”Start” stop_text=”Stop”]

    Or add a filter. Filter example :

    add_filter( 'tta__button_text_arr', 'tta__button_text_arr_callback');
    
    function tta__button_text_arr_callback( $text_arr ){
    	
    	// Listen button
    	$text_arr['listen_text'] = 'Listen'; // paste custem text
    	$text_arr['pause_text'] = 'Pause'; // paste custem text
    	$text_arr['resume_text'] = 'Resume'; // paste custem text
    	$text_arr['replay_text'] = 'Replay'; // paste custem text
    	// Record button text
    	$text_arr['start_text'] = 'Start'; // paste custem text
    	$text_arr['stop_text'] = 'Stop'; // paste custem text
    	
    	return $text_arr;
    }
    • This topic was modified 2 years, 2 months ago by Azizul Hasan.
  • The topic ‘How to change button text’ is closed to new replies.