You can find the source here https://community.nodebb.org/post/64258
NodeBB Click to Copy plugin
-
For the IP, I wish it was Click to copy, it would make life so much easier and it can be used anywhere in the page such as the footer.
-
Click to Copy a trick that is only possible with Flash, and it's also a security vulnerability. I'd rather not add it all, but I will consider making it a toggleable option from the settings page, with a sufficient warning.
-
How about it just highlights the text, and the users can just right click and copy it?
-
Any reason you need to know the IP address? They'll change every few weeks. So seems pointless.
-
@a_5mith said:
Any reason you need to know the IP address? They'll change every few weeks. So seems pointless.
I'm pretty sure he just wants the Address, as the IP would indeed be pointless.
-
Doesn't GitHub have something like this? I'm pretty sure that it's not flash...
-
It's flash unfortunately.
https://github.com/zeroclipboard/zeroclipboard -
I'm not so sure, or someone has figured out how to do it without flash on Chrome... I disabled flash and it still works. Checked the demo page to verify that it doesn't work with flash off.
-
Ah, your right. Seems there was a recently added method to copy, and it looks like it's been universally supported since a few months ago. zeroclipboard is only being used as a fall-back. I'll have to start adding this to my plugins, there's quite a few places it will be useful.
-
@Archeon Package updated
-
That's great! Thank you!