Add Password Generator on password protected page

It is not possible to modify the post submit meta boxes with a filter. But you can do that with JavaScript. This script will generate 10-12 random alphanumeric string and put it in the password field (if it is empty) when you click the Password protected radio button. $(‘#visibility-radio-password’).click(function () { // If there is … Read more

esc_html__() and __() not working within arrays

I created simple widget to find out why you have such a problem. Everything is working fine. Below I give you my code as an example. /** * Register widget */ function wpse_287570_register_widget() { register_widget(‘WPSE_287570_Widget’); } add_action(‘widgets_init’, ‘wpse_287570_register_widget’); /** * Create widget */ class WPSE_287570_Widget extends WP_Widget { public function __construct() { $op = array( … Read more