FRIHOSTFORUMSFAQTOSBLOGSDIRECTORY
You are invited to Log in or Register a Frihost Account!

Very simple javascript functions...

 


bladesage
I really need to know how to do these simple system functions with javascript:

-Copy
-Paste
-Cut

Please help. Thanks!!
woja
IE provides a method execCommand which enables you to do Cut, Copy and Paste.

see: http://msdn.microsoft.com/library/default.asp?url=/workshop/author/dhtml/reference/methods.asp

I don't think that Firefox or any other browser supprorts this and I've never used it.

I might be able to give more help if you could explain what it is you're trying to achieve.
bladesage
woja wrote:
IE provides a method execCommand which enables you to do Cut, Copy and Paste.

see: http://msdn.microsoft.com/library/default.asp?url=/workshop/author/dhtml/reference/methods.asp

I don't think that Firefox or any other browser supprorts this and I've never used it.

I might be able to give more help if you could explain what it is you're trying to achieve.


Well, I basically just want something (preferably javascript) to copy whatever the visitor selects to the clipboard.

Then, I want something to cut whatever the user selects into the clipboard.

Next, I'd like something to perform a select all on whatever (ie: the document, a form field, etc.) the user opens the context menu on (this is for a customized context menu).

Finally, I need something to paste the clipboard's contents into a form field.

I would love this ASAP, and it's a pain trying to figure out how to use the execCommand for what I need.

Thanks!!
Reply to topic    Frihost Forum Index -> Scripting -> Others

FRIHOST HOME | FAQ | TOS | ABOUT US | CONTACT US | SITE MAP
© 2005-2007 Frihost, forums powered by phpBB.