You can do this using follow snippet
// Add scripts to wp_head()
function child_theme_head_script() { ?>
<!-- Your HTML/JavaScript goes here -->
<?php }
add_action( 'wp_head', 'child_theme_head_script' );
Related Posts:
- JavaScript error (Uncaught SyntaxError: Unexpected end of input)
- How do you select a particular option in a SELECT element in jQuery?
- My javascript is returning this error: $.ajax is not a function
- Bootstrap – Uncaught TypeError: Cannot read property ‘fn’ of undefined
- jQuery: How can I create a simple overlay?
- Invalid or unexpected token on a very simple function
- How to make Bootstrap carousel slider use mobile left/right swipe
- How to get a cross-origin resource sharing (CORS) post request working
- Adding a page loader using jQuery
- jquery – return value using ajax result on success
- onclick event pass
- id or value
- How can I change CSS display none or block property using jQuery?
- Can you detect “dragging” in jQuery?
- Twitter Bootstrap Modal Form Submit
- How to overwrite a JavaScript core function?
- Automatically decrease font size for long words
- Custom function to rearrange attachments when creating posts – Almost there
- jQuery and AJAX Not working with Select Form Element
- Horizontal scroller with post_thumbnail’s
- Force wp_enqueue_scripts to the HEADER?
- $wp_customize customizer_preview_init not firing inside javascript
- Disable collapse of admin meta boxes
- jQuery code not firing on page despite registering and enqueuing scripts
- Ajax pagination works only first and third time
- How to properly add Bootstrap and JQuery Javascripts?
- how can I make $ work in wordpress for jQuery?
- WordPress Jquery Fade in, Fade out effect
- How to use Bootstrap with WP’s jQuery? [closed]
- Gutenberg Filtering Metaboxes by Post Format
- WordPress site in China times out on requests to youtube [closed]
- No data received
- Error when posting comment form: The error is TypeError: e[h] is not a function
- show element on page load from external url only [closed]
- CodeMirror on Custom Widget Textarea
- Sending click events to Google Analytics in WordPress: the easy way
- Accordion scrolls page too low after clicking on the title [closed]
- Exclude some scripts from removing unique scripts from head function
- Using Javascript to detect keypress event in text editor
- Passing jQuery into the WordPress media uploader
- jQuery undefined function error with WP jQuery, but works with Google CDN
- Bypass nonce value while trashing a post
- Adding JS to one page
- Simple text and image slider
- Display posts from another site using REST API in an asynchronous manner
- Why does my jQuery AJAX return 0?
- jQuery script is not working inside ‘head’ tag
- Why doesn’t jQuery use $, and how can I get it do so (GLOBALLY)?
- How do I include javascript/jquery image resizing with wordpress?
- Title on hovering on the featured image
- Loading a newer version of jQuery within WordPress
- WordPress 3.1 makes my drop down menu dissapear, jquery dont work
- Having trouble setting / modifying cookies
- Loading dynamic content with AJAX breaking jQuery
- Adding JavaScript file in Admin Panel
- How do I use jQuery to add the TinyMCE WYSIWYG editor to a textarea?
- How to change the text of the “You are about to permanently delete these items…” alert message when deleting media from the media library?
- why is my wordpress Jquery-Ajax call not working?
- Unable to get my javascript to work on my website – what am I doing wrong?
- Using jquery with wordpress using wp_enqueue_scripts
- get value from selected input
- jQuery – Toggle megamenu submenu items by click
- General Settings: display custom plugin field after Site Address field
- WP Customizer: Save a control state
- WordPress Insert not working with ajax
- WP AJAX API with JS file
- need to override function in jquery.ui.datepicker.js
- Can user meta be shown or hidden depending on user logged in status?
- Is there some jQuery conflict here?
- Dynamic WordPress editor in meta box
- Theme has superfish – how to add supersubs?
- How to modify iFrame content in an admin thickbox
- How to wrap posts into divs?
- jQuery Drill Down iPod Menu FOUC and Selecting Current page
- jquery.min has very long TTFB
- animate.style on wp-login.php
- Storing current page WP list table HTML data into a PHP variable
- Form validation before submitting
- bundled jquery in theme js not working with wp_localize_script
- How to toggle custom WP archive list
- I can’t enqueue Suggest.js in frontend – not added
- Jquery code won’t run loaded from WP, but run from console
- WordPress and Raty.js
- JQuery is not defined but jquery script is loaded in source [closed]
- search in jquery mobile returns blank page
- owl carousel not working after ajax load [duplicate]
- jQuery post method in admin menu
- jquery not working correctly in plugin options page?
- jQuery AJAX add json2 dependency?
- Running javascript in a child theme. Works in jsfiddle
- How to block action if post is “dirty”?
- $ not defined using jQuery in WordPress
- How to read the contents of single post through RSS feed
- jQuery Ajax / Modal admin event not firing since 3.6. Seems to not recognize “a” tag
- Auto Select Child categories on Multiple Dropdown – Jquery
- WordPress video end function [duplicate]
- jQuery Live Form Validation in WordPress
- bootstrap-slider.js by seiyria not working in wordpress
- Sliders with buttons [closed]
- Generate dynamic ID’s for each accordion button
- Impossible to update jQuery version from 3.1.0