www/js/prod_forum.js

Mon, 11 May 2020 17:32:08 +0200

author
Michiel Broek <mbroek@mbse.eu>
date
Mon, 11 May 2020 17:32:08 +0200
changeset 671
4b54d6f79d25
parent 565
dfc850e6ee1f
permissions
-rw-r--r--

Version 0.3.33 Added websockets framework. Added fermenter status messages to the websockets broadcast.


$(document).ready(function() {

 /**
  * This will copy the innerHTML of an element to the clipboard
  * @param element reference OR string
  */
 function copyToClipboard(e) {
    var tempItem = document.createElement('textarea');

    document.body.appendChild(tempItem);
    tempItem.value = e;
    tempItem.select();
    document.execCommand('Copy');

    tempItem.parentElement.removeChild(tempItem);
 }


 $('#copytoClipboard').jqxButton({ template: 'success', theme: theme, width: 150 });
 $('#copytoClipboard').click(function() {
  copyToClipboard(forumstr);
  window.close();
 });

});

mercurial