sir3453715
Forum Replies Created
-
yes I upgrade to the PRO version already, but when I setting “Where to filter?” to my custom taxonomy, but the “Available on” is empty and the custom taxonomy page is not the filter I want to show
“Where to filter?”
https://upload.cc/i1/2024/11/11/6WxOqp.png
“Available on” is empty
https://upload.cc/i1/2024/11/11/LSB6wD.png
Frontend
https://upload.cc/i1/2024/11/11/tjPCws.pngForum: Plugins
In reply to: [Loco Translate] some translate not working when po in Author paththanks for your help!
Forum: Plugins
In reply to: [Loco Translate] some translate not working when po in Author pathUmmm… I update the translate in LOCO Translate again, but didnt change any string, and it’s work now, but dont know why
and now I install LOCO Translate 2.6.7 version , not dev version, and it’s still working , thanks for the help
- This reply was modified 7 months ago by sir3453715.
Forum: Plugins
In reply to: [Loco Translate] some translate not working when po in Author pathI think the MO file is loading, and I try to create a new MO file by Poedit with true PO file and upload by FTP, but the string still cant be translate, and I change the path to custom or service, the translate cant working now,
Forum: Plugins
In reply to: [Loco Translate] some translate not working when po in Author pathOK, I install the dev version and test the string in Debugger page,
I get those result:“Running test for domain => Meihao-Taiwan-Trains
Have locale: vi_VN
~ filter:pre_determine_locale: none => vi_VN
No loader, is_textdomain_loaded() => true
Query: msgid “Flights TimeTable Search”
Calling __( “Flights TimeTable Search”,”Meihao-Taiwan-Trains” )
~ filter:gettext: “Flights TimeTable Search” => “航班時刻查詢表”
====>| msgstr “航班時刻查詢表”
Translated result state => true
Searching 5 possible locations for string versions
found in {wp_content_dir}/plugins/MeihaoTaiwanTrains/languages/Meihao-Taiwan-Trains-vi_VN.po => ‘Tra c?u chuy?n bay’
found in {wp_content_dir}/plugins/MeihaoTaiwanTrains/languages/Meihao-Taiwan-Trains-vi_VN.mo => ‘Tra c?u chuy?n bay’
2 matches in 5 locations; 3 files searched”but in frontend still cant translate the string, and the HTML is here
<div class="taiwan_trains_header"> <h2><?=__('Flights TimeTable Search','Meihao-Taiwan-Trains');?></h2> </div>
- This reply was modified 7 months ago by sir3453715.
- This reply was modified 7 months ago by sir3453715.
Forum: Plugins
In reply to: [Loco Translate] some translate not working when po in Author path?The MO translations have a problem with, not JSON files.
Forum: Plugins
In reply to: [Loco Translate] some translate not working when po in Author pathyes the determine_locale? return the language
and the string in Loco Translate
and here is my code:
function __construct(){ add_shortcode('MeihaoTaiwanFlightsFrontend', array($this, 'meihao_taiwan_flights_frontend')); add_action('wp_enqueue_scripts', [$this, 'load_css_js_to_shortcode_page'], 110); } /** Frontend Hook */ //ShortCode 載入模板 function meihao_taiwan_flights_frontend(){ ob_start(); echo "determine_locale:"; print_r(determine_locale()); echo " is_textdomain_loaded:"; print_r( is_textdomain_loaded('Meihao-Taiwan-Trains')); include MTT_DIR.'/templates/Taiwan_Flights_page.php'; $shortcodeTemplate = ob_get_clean(); return $shortcodeTemplate; } //使用ShortCode 頁面載入 css & js function load_css_js_to_shortcode_page() { global $post; if ( is_a( $post, 'WP_Post' ) && ( has_shortcode( $post->post_content, 'MeihaoTaiwanFlightsFrontend') ) { wp_enqueue_style( 'dashicons' ); wp_enqueue_style("meihao-taiwan-trains-css", MTT_URL.'assets/css/meihao-taiwan-trains.css'); wp_enqueue_style("jquery-ui-css", '//code.jquery.com/ui/1.13.2/themes/base/jquery-ui.css'); wp_enqueue_script("jquery-ui-js", '//code.jquery.com/ui/1.13.2/jquery-ui.js', ['jquery'], false, true); if(has_shortcode( $post->post_content, 'MeihaoTaiwanFlightsFrontend')){ wp_register_script("meihao-taiwan-flights-js", MTT_URL.'assets/js/meihao-taiwan-flights.js', ['jquery','wp-i18n'], false, true); wp_enqueue_script('meihao-taiwan-flights-js'); wp_set_script_translations( 'meihao-taiwan-flights-js', 'Meihao-Taiwan-Trains',MTT_DIR. '/languages/' ); } load_plugin_textdomain( 'Meihao-Taiwan-Trains',false, MTT_DIR . '/languages/' ); } }
Forum: Plugins
In reply to: [Loco Translate] some translate not working when po in Author pathdetermine_locale?and?is_textdomain_loaded? all true
I print them befor I load my html, get the true language and is_textdomain_loaded? print “1”Forum: Plugins
In reply to: [Loco Translate] some translate not working when po in Author pathI think the MO file is no problem, and how can I verify it’s getting read before I request ?
other string can be translate so maybe is be read already , I dont know how to verify thisForum: Plugins
In reply to: [Loco Translate] some translate not working when po in Author pathI write the string in html __(‘XXX’,’text-domain’), and use Loco Translate select the plugin > Edit template > Sync, than the string add to pot.
Then edit the language po > Sync > translate it.Forum: Plugins
In reply to: [Loco Translate] some translate not working when po in Author pathI know I asked before, but I think is the different problem so ask a new question.
The question was all string cant be translate in author path,and I have already solve that problem, but now is I add the new string to that pot and translate the new string, but new one cant be translate in frontend, old strings I translate before are work, so I think is different problem, my code didnt change only add new string
Forum: Plugins
In reply to: [Loco Translate] Translate not working when po in Author pathThanks for your help! I can translate the string in js now!
Forum: Plugins
In reply to: [Loco Translate] Translate not working when po in Author pathThank you I found the problem!
But I have other question for javascript translate,
I’m not sure is my code problem or what, I cant translate the string in js and I didnt see the json file
shloud I create by myself? or it will be auto created when I use “Loco Translate” to trans the string?
thank you for your help again
load_plugin_textdomain( 'custom',false, dirname(plugin_basename(__FILE__)) . '/languages/' ); wp_register_script("custom-js", MTT_URL.'assets/js/custom.js', ['jquery','wp-i18n'], false, true); wp_enqueue_script('custom-js'); wp_set_script_translations( 'custom-js', 'custom',dirname(plugin_basename(__FILE__)) . '/languages/' );
I have tried to deactive Slim SEO reactivate it again, and resave the permalink. but still 404
and I resend the email already, thx.
Forum: Plugins
In reply to: [WooCommerce] I have duplicate data in my woocommerce analytics reportOK I have already fix cant send email problem.
now it still get some duplicate data in Excel.