WP-admin redirects to login after adding SSL certificate

Go to your admin area, general settings, and update your “WordPress Address (URL)” and “Site Address (URL)” field value with https. and then update your permalinks setting, by simply click on “Save Changes” button. In case if you are not able to login to your admin area also, do this changes directly in your database. … Read more

Admin side jquery is not loaded

If you want to load Jquery, wordpress already provides a handler for it (its also the one in /wp-includes/js/jquery/jquery.js): function load_admin_script(){ wp_enqueue_script(‘jquery’); } add_action(‘admin_enqueue_scripts’,’load_admin_script’); note that the jQuery in WordPress runs in noConflict mode.

Insertng HTML and jQuery into a page that uses the Defaut template

There are 2 options: Copy the WooCommerce file into your theme, then make whatever changes you like. Since you’re using a default theme, you’d need to create a child theme. In this case, you’d copy /wp-content/plugins/woocommerce/templates/checkout/for-m-checkout.php (the whole file) into /wp-content/themes/yourchildthemename/woocommerce/checkout/form-checkout.php and do whatever you like – the child theme will also need a style.css … Read more

WordPress add script with custom type (x-jquery-tmpl)

Printing the script in the head is a method called do_item in the wp_script class. In this method you see this line: $tag = “{$cond_before}{$before_handle}<script type=”text/javascript” src=”https://wordpress.stackexchange.com/questions/262406/$src”></script>\n{$after_handle}{$cond_after}”; So, the script type is hardwired in the function. However, a few lines further on, you see this: $tag = apply_filters( ‘script_loader_tag’, $tag, $handle, $src ); This allows … Read more