Tagged: copy

0

Grunt Copy Only Changed/Watched File Only (Node.js)

Only copy modified file in “grunt watch”, see code bellow. Gruntfile.js //code for Gruntfile.js module.exports = function (grunt) {   var srcF = ‘D:/PROJECTS/2016/Website/’; var outF = ‘\\\\Computer\\d$\\2016\\Website\\’; //WINDOWS MAPPED DRIVE ie: Q:\2016\Website  ...

0

Javascript: Copy to clipboard with or without flash

function copy_to_clipboard(text) { if(window.clipboardData) { window.clipboardData.setData(‘text’,text); } else { var clipboarddiv=document.getElementById(‘divclipboardswf’); if(clipboarddiv==null) { clipboarddiv=document.createElement(‘div’); clipboarddiv.setAttribute(“name”, “divclipboardswf”); clipboarddiv.setAttribute(“id”, “divclipboardswf”); document.body.appendChild(clipboarddiv); } clipboarddiv.innerHTML='<embed src=”clipboard.swf” FlashVars=”clipboard=’+ encodeURIComponent(text)+'” width=”0″ height=”0″ type=”application/x-shockwave-flash”></embed>’; } alert(‘The text is copied to your...