Localized version offers upgrade to en-us version

(Answering my own question) It is now 1 week after posting my question. I just revisited the dashboard. There are now two updates available: WordPress 4.3.1–nl_NL and WordPress 4.3.1–en_US. So it looks as if the localized update takes some more time to prepare. I will not click anything right now, assuming that the update will … Read more

Script Localization doesn’t work

Copying from the answer here regarding variable scope Variables inside a function are only available inside that function. Variables outside of functions are available anywhere outside of functions, but not inside any function. Because of that, you need to add your $translations array within the kvkoolitus_load_comment_validation function, like function kvkoolitus_load_comment_validation(){ $translations = array( ‘value1’ =>’This … Read more

Generate PO File

You can use POedit to generate the PO file from source code: https://codex.wordpress.org/User:Skippy/Creating_POT_Files The problem for me is that my WordPress installation is running on an Amazon Linux server, which does not have a package in the repos for POedit and I couldn’t figure out how to install POedit on my server (only on my … Read more

Can any users change locale language?

You don’t need to work on any .mo files for allowing your users to switch between language. Loco translate plugin comes with this features. So what you need to do is to follow the steps below :- Navigate to Loco Translate menu Find and select plugin / theme you want to translate Create template file … Read more

Gutenberg block JavaScript localisation on Polyglots does not work

The first argument $handle of wp_set_script_translations() expects the script handle the text domain will be attached to. In your case it’s simpletoc and not simpletoc-js. The correct call would be: wp_set_script_translations( ‘simpletoc’, ‘simpletoc’ ); Another note: wp_set_script_translations() is available since WordPress 5.0 thus the function_exists() check isn’t necessary.

How to render a time-of-day string like ’16:42′ with a site’s chosen time format?

The trick here is using wp_date() in a peculiar way, giving it the time of day in seconds (as if it were 1970-01-01 16:42:18), then asking for it to be formatted in UTC. $time=”16:42:18″; if ( preg_match( ‘/^\d\d:\d\d:\d\d$/’, $time ) ) { //validate the $time $ts = intval( substr( $time, 0, 2 ) ) * … Read more

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)