Plugin Support
Dragos
(@dragosvrejiu)
Hello Mike,
I’m sorry for the late reply.
You can exclude pages from being translated using the following custom code:
Create an empty plugin like this: https://gist.github.com/sareiodata/76f701e01db6685829db
Add(and change the arrays with your desired slug pages that you want to exclude) the following code to the end of it:
add_action( 'plugins_loaded', 'trpc_exclude_tp_from_pages', -1 );
function trpc_exclude_tp_from_pages(){
$do_not_translate_path = array('contact');
$do_not_translate_path = array('home');
$do_not_translate_path = array('test-page-page');
foreach ( $do_not_translate_path as $path ){
if ( !empty($path) && strpos($_SERVER['REQUEST_URI'], untrailingslashit($path)) !== false ){
add_filter( 'trp_allow_tp_to_run', function(){return false; } );
}
}
}
Install it via FTP or activate it via WordPress like any other plugin.
Please let me know if this approach suits your needs!
Regards,