The documentation for Retina JS states that images need to have the data-rjs attribute set in order for them to opt in to using the script. This can be done using the third parameter of get_the_post_thumbnail() :
<?php echo get_the_post_thumbnail( get_the_ID(), 'thumbnail', array( 'data-rjs' => '3' ) ); ?>
Related Posts:
- Jquery in Child Theme
- Want to have the Post editor remembering the last editing position
- When does WordPress wrap inline scripts in CDATA?
- Question about the way that wp_register_script works
- My scripts-bundle.js file is getting sent to the browser as a stylesheet css file. Help!
- Add js into a theme [closed]
- What’s the proper way to include inlined javascript-source?
- 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
- how do i in ignore/disable/delete a javascript call from parent in child theme?
- Using JQuery to check for Rel Attribute of Image before Overriding It
- Getting a ‘slide down’ js panel implemented within WP
- WordPress 5.1 upgrade has lost the parent theme JavaScript
- How to use only scripts from new theme?
- Webflow Interactions on WordPress site?
- share wrordpress data between two shared hosts using REST API
- Will this js code work in a page template?
- JQuery Error in theme for .live is not a function [closed]
- 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)?
- WordPress Theme activation hook?
- “Unexpected error” on update requests
- How to prevent plugin, theme installation failures on WordPress?
- Is it possible to access Gutenbergs reusable blocks in CPT block templates?
- Generating the ogp tags in theme
- Error message “The page you are looking for is temporarily unavailable.” after editing a file [closed]
- Adding goodies to themes
- Child-theme breaks site
- A hook that runs only when the theme is previewed
- WordPress theme with multiple color schemes
- How can I have case-sensitive theme directory names when installed with Composer?
- how to remove the unwanted banner in wordpress static page [closed]
- Convert a complex webpage into WP theme
- When can changing a theme damage a website?
- How to remove background image from post navigation elements?
- variables in translatable text
- Load a different theme for IE less than 9
- Theme Check reporting an incorrect theme slug and text domain
- X-Axis of Site is Messed Up Because it is in Hebrew
- How can I use a logo in the header?
- How to create my own sidebar in Twenty Eleven child theme?
- How to find out if page_for_posts is showing (in order to style menu item)
- Buddypress User Settings template location? [closed]
- How to code static pages in WordPress
- Theme, WordPress Version, MySQL Version, PHP Version Update affected files and folders
- Can “Classic Editor” plugin help to replicate the old website / theme development experience from c. 2011?
- How to display footer menus in wordpress
- Color Options from Theme Customizer API not returning via get_theme_mod()
- How do I manually revert back to my old theme?
- Modifying the markup in the Tag Cloud widget?
- Debugging in WordPress at Theme installation [duplicate]
- understanding theme hierarchy
- wp_enqueue_style $dep argument does nothing?
- Posts as filtered list – expandable
- Is it a good practice to disable wpautop for premium themes?
- How to remove current theme customizations
- linking to an svg through comments_popup_link
- How to use custom page templates in a theme that hides page template option?
- Create QuickStart Package for WordPress just like in Joomla
- How to include stylesheet in custom admin using parent_slug
- After installing a free theme, my wordpress turns into text mode when accessing remotely
- Jquery Theme Roller to WordPress
- Implementation of language_attributes function
- why is this script not working on my site
- is theme network enabled?
- Custom theme – pages in menu
- remove preloader in WordPress theme [closed]
- Pharmacare theme login page / login modal redirection to custom URL
- Theme translates the_author_posts_link. How can I remove their translation?
- theme installation not working
- wordpress-theme 2017: featured image behaviour: where to set the height of the featured image?
- Changing a parent theme safely
- Trying to create a child theme with plugin
- How exactly does WordPress load themes from api.wordpress.org?
- Own Theme custom CSS does not display in editor but works in page
- Remove Read More Buttons
- SSL errors when I activate my custom theme
- Theme-based character encoding issue
- Linkedin not returning right info
- How to show taxonomy in WordPress shortcode
- how to load rtl.css file before style.css [duplicate]
- CSS/JS is not working in multi lang installation
- Error while downloading WordPress themes
- Theme stops media uploader from working
- div having different appearances in different themes
- Create a live demo gallery for themes
- Using wp_enqueue_script with social media buttons?
- Satoshi WordPress Theme – Portfolio SetUp Issues
- Lightword Theme – only one menu item
- How to create an Single-Portfolio page?
- Page structure using The Customizer Api
- theme 2016 – customize css – nothing happens
- Can’t upload the theme
- “Parse error: syntax error, unexpected” and the WordPress Theme Editor no longer working!
- Installing themes from an external website [closed]
- Best Practice Jumbotron Image for WordPress ~ Responsive
- How to make a page extend full screen [closed]
- Should you directly edit Template Parts and Templates from themes?