Comments (32)
This is a very tricky problem. For security reasons, JavaScript does not
typically have
access to the system clipboard.
There are various work-arounds (some them are already implemented in
ShellInABox), that
on some platforms give limited access to the clipboard. But in practice this is
a hard
problem to solve. And it never quite works seamlessly.
I have some ideas that I want to try out at some point. But for now, you will
have to
live with the internal clipboard (i.e. you can copy and paste within
ShellInABox, but
not exchange data with any other application). And even going forward, I might
not be
able to fix this completely.
I'll keep this issue open for a while, in case some of my experiments show that
I can
improve the user experience -- however gradually. Thanks for reporting this
issue.
Original comment by [email protected]
on 4 Dec 2009 at 10:19
- Changed state: Accepted
from shellinabox.
This is a bit of a hack, but their test seems to work for me in FF 3.5, Flash
10.0 r42:
http://code.google.com/p/zeroclipboard/
Or maybe use a Java applet?
http://www.javaworld.com/javaworld/javatips/jw-javatip61.html
Other option is maybe making use of HTML5 drag and drop support?
Thoughts?
Original comment by [email protected]
on 12 Dec 2009 at 2:30
from shellinabox.
[deleted comment]
from shellinabox.
what about having a seperate "tab" with a form that you can paste text into and
then
click a submit button and it submits that text to the shellinabox clipboard?
Original comment by [email protected]
on 27 Mar 2010 at 12:26
from shellinabox.
anyterm's approach is to allow the user to click a control that pops up an
input box
to allow the use of the browser's mechanism for pasting.
http://anyterm.org/
Original comment by [email protected]
on 30 Mar 2010 at 11:21
from shellinabox.
I would also like to see a way to input and output data into the system
clipboard.
Best way would be a context menu option which can send and retrieve data from an
input box, like anyterms way. But maybe looking nicer with an jQuery Overlay or
something like that.
Hope to see this feature soon!
Original comment by [email protected]
on 11 May 2010 at 7:46
from shellinabox.
Any update on this? HTML5 drag and drop support seems like a simple first step.
I'd be happy to test out any alpha versions...
Original comment by [email protected]
on 22 Jul 2010 at 1:10
from shellinabox.
This is the only reason I sometimes still need to SHH directly instead of using
Shell in a Box.
The simple solution suggested by Chrischtian doesn't look so hard to implement
and OK to live with.
Hope to see any update on this issue soon, too.
Original comment by [email protected]
on 12 Aug 2010 at 2:53
from shellinabox.
I'm with everyone else on this. I LOVE this tool, but myself and my users
really need this function. Hope to hear something soon!
Original comment by [email protected]
on 16 Sep 2010 at 3:47
from shellinabox.
Here is a quick proof-of-concept patch against the current SVN head that adds
support for dragging and dropping text into a shellinabox session if the
browser supports HTML5 drag-and-drop. It has only been tested with
shellinabox/demo/demo.html
Original comment by [email protected]
on 22 Sep 2010 at 5:48
Attachments:
from shellinabox.
thanks a lot for that but i tought is still something wrong when i vim a new
file,
anyhow ,thanks ,i wanna you developed it to a full ssh terminal
thanks again
Original comment by hepin1989
on 1 Dec 2010 at 5:14
from shellinabox.
I'm not quite sure I follow what your problem is. I just tried dragging some
text into a shellinabox terminal session with vim in the foreground. Worked
nicely. This is with the patch applied to a "real" installation of shellinabox
on Ubuntu 10.04.
Maybe I should better explain how it works: Just highlight some text in another
window then drag that highlighted text into the shellinabox browser window.
Note that not all applications support dragging highlighted text. Any browser
should support this, which is a common use case for me and probably others.
Original comment by [email protected]
on 1 Dec 2010 at 6:18
from shellinabox.
To make it clear. You can highlight, go to edit->copy and it will copy fine.
What does not work is if you highlight right click copy. That does not send to
the OS clipboard, but it will allow you to right click paste inside the window.
Original comment by [email protected]
on 1 Dec 2010 at 7:35
from shellinabox.
Yes, copying text out of a shellinabox terminal session is already possible. My
patch is currently the only way to get text *into* a shellinabox terminal
session.
Original comment by [email protected]
on 1 Dec 2010 at 7:45
from shellinabox.
aha,thanks alot ,zod..
Original comment by hepin1989
on 4 Dec 2010 at 2:00
from shellinabox.
One possible solution
a) Open some site like http://www.pastebin.com and post your text
b) Use wget inside the shell if ssh to download the snippet
Other solutions
a) Use your own server (simpler and safer) for pastebin
b) Use some kind of remote control automation (cnee or something on Linux)
Original comment by [email protected]
on 9 Dec 2010 at 3:45
from shellinabox.
This is the only thing keeping me from using shellinabox. If true copy, paste
becomes available and works dependably, I will switch to using shellinabox full
time. It's great otherwise!
Original comment by [email protected]
on 15 Dec 2010 at 8:06
from shellinabox.
Firefox users can avail themselves of the add-on "AllowClipboard Helper", which
will add a policy override for clipboard access to a Firefox configuration file
on a per site basis. The only "problem" is that it's necessary to use the mouse
to select Edit/Paste from the Firefox menu (since the alt-e key is intercepted
by the shellinabox.)
A second workaround is AutoHotKey on Windows and Autokey on Linux. These
keyboard macro utilities stuff clipboard contents into the keyboard directly
(as if typed.) An added benefit of these solutions might be the ability to
create other sorts of scripts to automate various server processes on the
client/browser side.
By the way, Autokey is written in Python and uses Python as its scripting
interface, so that its capabilities are pretty much open-ended. I'm not sure if
there's anything similar for Windows.
Original comment by [email protected]
on 18 Jan 2011 at 3:11
from shellinabox.
Solution:
Use the browser's Edit->[Copy|Paste] menu to copy and paste from/to the
application as opposed to using the shellinabox console menu via right click.
Original comment by [email protected]
on 17 Aug 2011 at 5:25
from shellinabox.
[deleted comment]
from shellinabox.
Wow, this does work now (in both Chrome-13/Linux and Firefox-5/Linux). I know I
tried this before and was only able to copy data _out_ of a shellinabox session
using this method. The only way I was ever able to get data to paste _into_ a
shellinabox session was with my patch. Apparently browser upgrades have fixed
this issue!
I think the drag-and-drop patch should still be considered though, it can be
very useful in certain work-flows.
Original comment by [email protected]
on 17 Aug 2011 at 6:28
from shellinabox.
Mint, thanks for announcing that it works! You are absolutely right... I'm
using Chrome 15.0.856.0 (Developer Build 97128) and it works great.
Thanks again taylor :)
Original comment by [email protected]
on 17 Aug 2011 at 6:31
from shellinabox.
Here is a simple patch that prompts the user to enter the text he'd like to
paste.
It is not integrated to the OS clipboard because to be honnest I've never seen
any such hack work reliably among browsers, but at least it's a quick way to
transfer text.
It adds a menu entry in the context menu "Paste from browser"
Original comment by [email protected]
on 7 Mar 2012 at 12:25
Attachments:
from shellinabox.
Patch applied to 2.11.
Original comment by [email protected]
on 31 Mar 2012 at 7:13
from shellinabox.
Any chance drag-and-drop will make it in? Are there changes that need to be
made to get the patch accepted?
Original comment by [email protected]
on 1 Apr 2012 at 12:55
from shellinabox.
Path for html5_drop_support applied to 2.11.
Original comment by [email protected]
on 1 Apr 2012 at 1:55
from shellinabox.
[deleted comment]
from shellinabox.
Going forward it should be perfect if one could copy/paste between shellinabox
terminal and os clipboard as it is with standard terminal. I am not a
programmer so I do not know how much effort it requires though.
But definitely this would make shellinabox top killer app:-)
Original comment by [email protected]
on 16 Jun 2012 at 4:11
from shellinabox.
Excellent product!
Me, too, using Google Chrome, am missing the ability to paste plain text into
the command window. I can do it through Microsoft Internet Explorer 8.
Original comment by [email protected]
on 9 Jul 2012 at 5:45
from shellinabox.
Pasting works for me in Chrome, but no Firefox, using Ctrl+Shift+V (I'm using
Windows).
Original comment by [email protected]
on 29 Aug 2012 at 7:23
from shellinabox.
Cool! I don't know know why I didn't think to try that keyboard shortcut
before.
For me on Linux (EL6.1 derivative), it works on Chrome 21 but not on
Firefox 11.
Original comment by [email protected]
on 29 Aug 2012 at 9:24
from shellinabox.
I'm using this patch in 2.11 and it makes things a lot nicer.
However, one issue that I have is that it looses all formatting in the process.
If I past in a list of names, what appears in the shell is all those names with
the newlines replaced by spaces.
Is there any way to preserve newlines, tabs, etc in this process?
Original comment by [email protected]
on 1 Oct 2012 at 11:23
from shellinabox.
Related Issues (20)
- Not working with windows RT HOT 2
- Stunnel with shellinabox
- New (unofficial) Release:
- ear
- There doesn't seem to be a way to disable SSL 3.0 protocol HOT 3
- Unable to get audible beep
- gethostbyname_r some errors on AIX 6.1
- cant access shellinabox with ie HOT 1
- ERR_SSL_VERSION_OR_CIPHER_MISMATCH HOT 1
- Browser loops on connectivity problems
- How to run few commands before startup? HOT 1
- Delay after typing in shellinabox HOT 2
- How to pass credentials to SSH command
- "-" key does not work in firefox HOT 3
- Decouple vt100.js from main project
- shellinaboxd: unrecognized service HOT 3
- Copy paste not working as expected HOT 1
- how to open and interact with shellinabox in a custom html page
- Prompt behind horizontal scroll bar
- migration to github or bitbucket ? HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from shellinabox.