Hide reply button after moveForm is called

Ended up using jQuery to solve this. The form moves around using javascript anyways so it doesn’t break anything for users with js turned off. //when reply button is clicked hide it $(“.comment-reply-link”).click( function() { $(this).hide(); }); //when cancel button is clicked reshow reply button $(“#cancel-comment-reply-link”).click( function() { $(“.comment-reply-link”).show(); });

Morris.js for WordPress?

Create js folder in your theme directory then save Morris.js into it. it is not mandatory to store it in js folder you can store it anywhere else but i recommend to do it to seprate javascipt files from other files. Add follwing action into functions.php file function custom_scripts() { /* Include Scripts */ wp_enqueue_script( … Read more

WP_enqueue_script() loads them always in wp_footer()?

All of these scripts are already registered to print in the footer. See wp-includes/script-loader.php for details. When you try to register the scripts again WordPress doesn’t change that. The workaround would be to register a new script for wp_head with those scripts as dependencies (the third parameter of wp_enqueue_script()). Do not register the scripts in … Read more

Can I include Javascript/jQuery in a page?

You need to make sure that jQuery is loaded, so that you can use it. In functions.php: function namespace_enqueue_scripts() { if ( is_page( ‘slug-of-new-page-you-are-creating’ ) ) wp_enqueue_script(‘jquery’); } add_action( ‘wp_enqueue_scripts’, ‘namespace_enqueue_scripts’ );