I have found a way by using nicEdit here’s the tutorial.
In order to get this fully functioning, I had to amend my script slightly.
jQuery(".stickers img").click(function(){
var img = jQuery(this).parent().html();
var text = jQuery("#respond .nicEdit-main").html();
jQuery("#respond .nicEdit-main").html(text + img);
});
I hope this helps someone.
Related Posts:
- How do I link a JavaScript file to a HTML file?
- JavaScript runtime error: ‘$’ is undefined
- JavaScript Loading Screen while page loads
- Force a default browser on my android phone using a simple html shortcut page
- Set selected option of select box
- Click button copy to clipboard
- How to make html table vertically scrollable
- How to make a simple image upload using Javascript/HTML
- How to make Bootstrap carousel slider use mobile left/right swipe
- How to Show External website inside another page without iFrame? [closed]
- bootstrap 3 navbar collapse button not working
- Display XML content in HTML page
- Bootstrap carousel not sliding
- Play/pause HTML 5 video using JQuery
- jQueryUI dialog width
- Clear form fields with jQuery
- How to call a webservice method from an html page [javascript] with out refresh the page
- Javascript – ERR_CONTENT_LENGTH_MISMATCH
- Random background images CSS3
- $(document).ready(function() is not working
- Show div #id on click with jQuery
- How do I remove a box-shadow effect from an element when another element is hovered?
- Slide right to left?
- jQuery UI Datepicker not working
- how to get the comment ID in the front end when the REPLY button is clicked?
- How to make an WordPress element sticky? [closed]
- Accordion scrolls page too low after clicking on the title [closed]
- Adding a slide toggle on WordPress
- specifying relative file paths in WP with jQuery requests not working
- How to display comments length
- How to keep HTML form field that is conditional hidden with javasript hidden after page reload?
- JQuery Counter Limit not working for WP Comment Textarea
- click event to unhide something after ajax not firing
- Insert a Featured Video
- How to use JQuery Marquee in WordPress?
- JQuery script working locally on desktop, not working on WordPress + Divi
- Getting click on item to open closest relevant element (popup) with jQuery
- How can publish my bootstrap created table ( huge amount of data) on my word-press theme?
- jQuery for Fade Preload Causes My Site Favicon to Disappear from Tab of Browser
- how to allow download after newsletter subscription?
- jQuery function not working in WordPress but works in jsfiddle
- Site images are fixed in front of my site content [closed]
- How can I add a new lib path without call each one on the header?
- change the icon of a custom post type in WordPress to use twitter boostrap
- can’t make jQuery work (change image on time interval) [closed]
- Contact Form 7 – Submit Form not working After Ajax Request [closed]
- jQuery equivalent of JavaScript’s addEventListener method
- What is content-type and datatype in an AJAX request?
- When and why to ‘return false’ in JavaScript?
- How is JavaScript .on() method defined?
- Create table with jQuery – append
- Get checkbox value in jQuery
- How can I expand and collapse a using javascript?
- Using “×” word in html changes to ×
- JQuery: ‘Uncaught TypeError: Illegal invocation’ at ajax request – several elements
- How to enable button onClick functions and java script in wordpress post
- How do I send this form's output to a new WordPress page?
- Annoying “JQMIGRATE: Migrate is…” in console after update to WordPress 4.5
- Update jquery version
- WP set auth cookie using Ajax is not saved to browser
- ajax live search for post title
- WordPress Ajax always returns a 404 error
- Modify Custom Field in Media Library using JavaScript
- Comment form vaildation
- Enqueuing jQuery in plug-ins
- Script doesn’t load because of a javascript MIME type error
- TinyMCE – TypeError: r is undefined
- Auto-detect javascript errors and warn theme user
- combining js scripts from a js newb [closed]
- Heartbeat API: How to access data already enqueued?
- Jquery integration with my theme
- How to stop focus() in custom js from scrolling to footer?
- Getting post meta in the flex slider
- Removing jQuery from footer
- Using bootstrap-slider and bootstrap-switch in wordpress admin panel
- WordPress jquery files not being enqueued
- Register jQuery – OOP WP
- How to isolate code to the post edit screen
- jQuery code not working in widgets page
- WordPress error when replacing local jQuery by externally-hosted
- Create special WordPress slideshow with “jquery.cycle.all.js”
- WordPress Front-End Theme Editor
- WordPress 3.2.1: jQuery is not defined, breaks Admin panel
- inner anchor scrolling with wordpress
- Bootstrap and jQuery error: $ is not defined
- Auto next upon clicking image without clicking Next button
- Doing Math with Gravity Forms List
- Remove button from page if viewed through Customizer
- Target a specific page/template in jQuery
- Multiple level category drop-down three levels is not working
- standard callback function for wp_list_comments
- JQuery and Javascript to pan image
- How to add JS snippet before closing tag?
- Show/Hide text after the first paragraph
- Check with jQuery value of checkbox from custom admin panel
- WooCommerce – PrettyPhoto appending URL with #prettyPhoto
- Change image on post title hover (more than one instance) – Jquery
- How to fire jQuery after $(window).on(‘load’)
- how to make this work with jquery 1.12.4 [closed]
- Theme variation conflict with jquery select2 dropdown