Click anywhere within <pre> code tags to automatically copy to clipboard.
A simple little plugin that automatically copies content in <pre> and <code> tags to clipboard (when clicked). Other plugins out there do the same but create a little [COPY] button that you have to aim for. With mine, you don’t have to aim your mouse or finger at any button, simply click anywhere on the code block and it copies the whole thing.
With all the guides out there sharing code-commands, especially on this site, it’s about time somebody made a plugin to save us all a little time from having to highlight and copy-paste bits of text back and forth. It’s especially time-saving when trying to copy large globs of code that scroll off-screen or trying to manage on your mobile phone.
- The plugin is free for your personal/commercial use, but do buy me a beer if you like it. Enjoy! 🙂
- I’m not responsible for what you do with it. If you have issues, you can ask for support on the WP.org repo.
Download Code Click-to-Copy:
What is the license of the plugin?
Right now, it’s officially under GNU GPL (as required for ALL WordPress plugins).
Thanks I was confused with the “No, you cannot copy and repackage/resell them.” which goes against the GNU GPL.
Not that I am going to do that anyway. 🙂
Yeah, you’re totally right! It’s old copy-paste verbiage. 🙂
Hey Johnny, Just what I was looking for. Is there any instructions or documentation I can find for this?
What documentation would you need? It’s really simple. Just activate and it works.
I confirm that it doesn’t work with Divi…
Thanks! Great simple plugin, exactly what i was looking for