javascript - how do I copy and paste images in php -


how copy , paste uploaded images in php. when click on copy button copy uploaded images. when click on paste button paste copy image using javascript , php

<script type="text/javascript"> function clicked(){ var src = document.getelementbyid('copy').value     document.getelementbyid('paste').value = src;  } </script> 

html:

<ul id="image_list">     <li><img src="elements/1.png" id="copy" width="640px" height = "480px" /></li>  </ul> <button onclick="clicked();"> copy </button> 

check this, should you. else asked question way. search first, please. :)

<script> function copy() { if(window.clipboarddata) { window.clipboarddata.cleardata(); window.clipboarddata.setdata("text", document.getelementbyid('txtacpy').value); }  } function paste() { if(window.clipboarddata) {    document.getelementbyid('txtapaste').value = window.clipboarddata.getdata("text"); }  } </script> <a href="javascript:copy();">copy</a> <br /> <input type="text" name="txtacpy" id ="txtacpy"/> <br /> <a href="javascript:paste();">paste</a> <br /> <input type="text" name="txtapaste"  id="txtapaste"/> 

Comments

Popular posts from this blog

Android : Making Listview full screen -

javascript - Parse JSON from the body of the POST -

javascript - Chrome Extension: Interacting with iframe embedded within popup -