To print JavaScript code to your page, you have several paths to choose from. The most obvious would be the wp_footer action. Just hook a function to it and make it print your JavaScript/jQuery code, wrapped in <script /> tags.
// EDIT
As an addition, if your custom JavaScript/jquery code is static (i.e., there are no dynamic parts in it), you should put it in a separate JS file and enqueue it with the lib as dependency. But you explicitly asked for printing so that’s what I answered.
As for your comment, as long as your code doesn’t have to be executed before the page has been rendered—which doesn’t seem to be the case, according to your question (document.ready)—this is just best practice to enqueue script files in the footer.
Related Posts:
- Best practices for a Style/CSS based theme options page?
- How to use media upload on theme option page?
- Add a page outside of the current theme?
- Jquery in Child Theme
- Want to have the Post editor remembering the last editing position
- Switch Theme Through Options Panel
- When does WordPress wrap inline scripts in CDATA?
- How to make alert for new version on theme options?
- How to mark an option as selected
- How can I show more than 15 themes at a time in the admin menu?
- How to go about pre generating css file with variables from theme options
- Question about the way that wp_register_script works
- Does uninstalling a WordPress theme delete its database values?
- Cannot find the code for “Edit This” link in posts in a specific theme
- Defining different theme for Blog posts page
- How to set different settings for a mobile theme?
- My scripts-bundle.js file is getting sent to the browser as a stylesheet css file. Help!
- Disable Theme API / Front end (for API only environment)
- Add js into a theme [closed]
- How to understand a specific bit of WordPress syntax
- Should a child theme share the same theme options row as the parent, or should it have it’s own options row?
- Creating a theme options page
- Retina JS not working
- How Do I Use A Custom Mobile Theme?
- How can I make some themes usable only by admins?
- Custom options below pages/posts editor?
- JavaScript Files Registered in Parent Theme Won’t Load When Calling wp_enqueue_script() in Child Theme?
- Angular integration with homepage
- Twenty fifteen theme – change responsive menu condition
- Redux callback action
- Preserve theme settings when migrating from local to live
- how do i in ignore/disable/delete a javascript call from parent in child theme?
- Functions containing parameter ‘yourtheme’
- What is the “pub” theme? [closed]
- Passing dynamic options from backend to frontend
- Color Options from Theme Customizer API not returning via get_theme_mod()
- Using JQuery to check for Rel Attribute of Image before Overriding It
- Getting a ‘slide down’ js panel implemented within WP
- Issue with theme mod options during domain migration
- WordPress 5.1 upgrade has lost the parent theme JavaScript
- .PO file is found but I don’t see translations: how to debug the problem?
- How to add some php code in header.php using plugin
- WordPress activate theme error $pagenow
- How to use only scripts from new theme?
- Setting a new default template for the creation of a page
- Cannot update a file for my theme
- List of categories instead of dropdown menu selector in admin options
- Switching among theme customizations
- Webflow Interactions on WordPress site?
- share wrordpress data between two shared hosts using REST API
- how to create a section inside a section with theme options customizer
- Warning: call_user_func() expects parameter 1 to be a valid callback
- Will this js code work in a page template?
- Create /archive page in WordPress Theme
- JQuery Error in theme for .live is not a function [closed]
- Church hope them issue
- Divi theme including javascript
- Help!!! Old theme doesn’t load scripts and conflitcs with plugins
- How to remove pop up on website (css changes not visible)?
- How can I allow the Editor Role to change Theme Settings?
- Undefined offset: 0 in > […] /wp-includes/capabilities.php on line 1067
- Editing Links in the Footer of WordPress Themes with Base64 Encrypted Code?
- Display custom_background outside wp_head()
- Can we create a child theme for a premium child theme built on Genesis framework?
- WordPress ignoring specified template for front page. Why?
- Migrating October CMS to WordPress
- How to start learning CSS and theme development?
- How do I make the category template display full posts instead of partial posts?
- PHP Parse error: syntax error, unexpected end of file, expecting elseif (T_ELSEIF) or else (T_ELSE) or endif (T_ENDIF) on line 230 [closed]
- How does a Child Theme works?
- Finding wordpress file in theme editor using the theme name
- Private theme update with zip archive without deactivating the theme
- Published site reverts without changes to theme
- How to apply different themes with custom design in one site?
- How to make Additional css changes global all across the web pages on WordPress website?
- WordPress without a theme – help!
- Problem Installing a Premium Theme– File Permission Issue on a Mac, Local Machine? [closed]
- Variant of the same theme for each page
- can’t see aditional themes in control panel
- What’s the default order used by WordPress to load CSS files?
- How can I remove all traces of a theme?
- Updating WordPress Theme Files
- A thin line between native wordpress bahaviour and 3rd party themes
- Display Pointer only once?
- From where wp ecommerce is loading plugin theme files?
- Making first post wider than other posts on home page(default)
- How to push a theme update for a ciustom theme used on multiple independant self hosted sites?
- Removing a widget via theme editor
- Can’t embed certain youtube videos into theme
- How to customize a section of a widget only on certain pages or page
- How do I get the featured image to sit below the header in the twenty nineteen theme?
- Basic wordpress search shows no results
- How do I remove search bar that isn’t a widget?
- TwentyFourteen Theme : Changing grid layout
- WordPress two sidebar layout or theme
- How to remove the option data of a theme when that theme is removed?
- Resetting Themes Folder to Default
- How to Hide Blog Post Author?
- Convert theme to be based on Bootstrap?
- Themes admin page lists a theme, but it fails to delete and is not present on disk