I am using version 1.11 and i am to be able top copy / paste a screenshot or picture in the response field.
I have seen issues with it in older versions but i thought it was solved?
@CashDesk
I'm using v1.11-rc1 and I'm able to copy/paste screenshots just fine. Are you using Windows by chance? If so, we've noticed issues with copy/pasting images from Word and such. It happens to some but not others so it's hard to pinpoint the exact issue. With that being said, we are actively working to find and address the issue.
Cheers.
@JediKev yes we are using Windows. I have tried to copy / paste from different sources like paint, word, greenshot but its seems not working. The only solutions seems to be save the images and attach it to the ticket which is not very handy these days.
@JediKev
This is the error message we get per mail when a copy/paste was not successful.
Maybe this helps to find the solution:
[INSERT INTO ost_attachment SET file_id = 5996, type = 'D', object_id = 35287]
Duplicate entry '35287-5996-D' for key 'file-type'
---- Backtrace ----
@CashDesk
It鈥檚 saying that a draft tried to save with an inline attachment and there was already a record in the database for it.
What鈥檚 your database situation? Just one database server or multiple with replication, distributed read/writes, etc.?
Cheers.
@JediKev , Just one database only. It can be that the error is the result of more times paste in the message. Mostly copy/paste doesn't work but sometime it does. I cannot find a logic pattern in it
We are having the same problem. Version 1.11, using windows.
[INSERT INTO ost_attachment SET file_id = 3451, type = 'D', object_id = 31296]
Duplicate entry '31296-3451-D' for key 'file-type'
---- Backtrace ----
I also get errors in the console when trying to paste. Chrome (69). I don't know if it's related or not.
Uncaught TypeError: Cannot read property 'insertNode' of null
at init.nodeToCaretPositionFromPoint (eval at
at init.buildEventPaste (redactor-plugins.js?d4e240b:1048)
at HTMLDivElement.i (jquery-3.3.1.min.js?d4e240b:2)
at HTMLDivElement.dispatch (jquery-3.3.1.min.js?d4e240b:2)
at HTMLDivElement.y.handle (jquery-3.3.1.min.js?d4e240b:2)
The given range isn't in document.
If a "me too" is helpful count me in. In my console (Firefox) I see:
IndexSizeError: Index or size is negative or greater than the allowed amount redactor.min.js:1
nodeToCaretPositionFromPoint https://example.com/ticket/js/redactor.min.js?7b1eee8 line 12 > eval:1
nodeToCaretPositionFromPoint self-hosted:976
insert https://example.com/ticket/js/redactor.min.js?7b1eee8 line 12 > eval:1
insert self-hosted:978
onreadystatechange https://example.com/ticket/js/redactor.min.js?7b1eee8 line 12 > eval:1
i jQuery
If a "me too" is helpful count me in. In my console (Firefox) I see:
IndexSizeError: Index or size is negative or greater than the allowed amount redactor.min.js:1
nodeToCaretPositionFromPoint https://example.com/ticket/js/redactor.min.js?7b1eee8 line 12 > eval:1
nodeToCaretPositionFromPoint self-hosted:976
insert https://example.com/ticket/js/redactor.min.js?7b1eee8 line 12 > eval:1
insert self-hosted:978
onreadystatechange https://example.com/ticket/js/redactor.min.js?7b1eee8 line 12 > eval:1
i jQuery
I currently have this same problem, and the message presented in firefox is the same
@asesoriait
Upgrade to the latest stable version of v1.12.
Cheers.

I still get this problem with Firefox
Are you guys trying to paste directly from the clipboard like take a screenshot and immediately paste (on Windows)? If so it鈥檚 not going to work, you have to copy the final, saved image and paste that (like take screenshot, go to where it saves, right click + copy, then paste). We are using the latest free version of the text editor and it seems to have issues with Windows in general. We have future plans to update the text editor to a modern editor that should eliminate all problems people are experiencing currently.
Cheers.
same problem :(
@balojs
Idk then. All I can say is try attaching the files whilst you wait for the new editor to be implemented.
Another thing I've heard people do is pasting the image until it does actually paste. Meaning, if you paste and it doesn't work, wait until the request finishes and paste again. Repeat this until it actually pastes.
Cheers.
It seems to work fine if you always paste at the end of a line.
Never hit enter (CR) before you paste, and never paste in an empty field.
Just upgraded from 1.11 to 1.12.
In 1.11 I gave up trying to paste - only used the insert button after saving the snip image.
I'm getting the same results as FG-Lars (i'm creating an FAQ). If I type something and then paste it works.
On a blank line it tends to generate a 1062 error - but not every time.
@LeslieDesser
Interesting. I鈥檒l have to play around with this to see if there鈥檚 anything we can do for now.
Cheers.
I upgraded from 1.9 to 1.12 and now copy / paste only works in IE.
I get the DB Duplicate entry error with FF and Chrome. All 3 browsers worked fine in 1.9.
Same here. On v1.12.2 (a5d898b), works in IE but not in Edge or Chrome - get the same Duplicate entry '40-41-D' for key 'file-type' DB error.
Reliably reproduced as a very common use case:
You get some brief feedback, then nothing, just the cursor goes back to the end of the text.
attach XHR request appears to have succeeded (HTTP 200) but System Logs and admin email show DB error.
Trying the paste again doesn't work. Only solution we have is to enter a single space before pasting the image. But we're expecting end users to know this, or work it out, and they are extremely frustrated by it.
A few weeks ago I also upgraded from 1.12 to 1.12.2 and still having problems.
I use Chrome and putting some text on a line before pasting seems to work.
On FAQ editing it seems to work always. On creating a ticket I'm not so sure - I need to do some proper testing.
A user whom I asked to test it creating a new ticket reports back that typing something first does not work for him. I do not know which browser he is using - I can check if necessary.
After some more testing here, it isn't quite as simple as I said above...
It EITHER
So I'm wondering if the attach from the first failed paste attempt did succeed, then the second paste succeeded, as people have already pointed out, but now the image attachment already exists, hence the db error. Between the two, we now have the image in the box and at least one copy in the db, so it all eventually ties up.
+1
@CashDesk @colinbarnard @yois615 @asesoriait @balojs @FG-Lars @LeslieDesser @denverwinks @randomsock @MattSBR
The new editor is available with v1.14-rc1:
We don鈥檛 recommend running in production as it鈥檚 an RC but you can install a separate instance for testing.
Cheers.
Thank you.
I have installed it and will report back after some testing.
Just an install gripe I keep meaning to mention each time it catches me out.
After the the install there is a message:
_Please take a minute to delete setup/install directory (../setup/) for security reasons._
There is no such directory as: setup/install
The message should rather say:
_Please take a minute to delete the setup directory inside the upload directory, for security reasons._
Filling out a ticket as an agent: The Cancel button does not work. Same for reset.
Logging in as a user: Creating a new ticket: Paste of image is OK. Pressing Reset clears Help Topic and Issue Summary but does not clear the image or any typed text.
@LeslieDesser
Just an install gripe I keep meaning to mention each time it catches me out.
After the the install there is a message:
Please take a minute to delete setup/install directory (../setup/) for security reasons.
There is no such directory as: setup/install
The message should rather say:Please take a minute to delete the setup directory inside the upload directory, for security reasons.
Well you are actually supposed to _upload_ all contents of the upload folder to your HTML directory. If you do it properly the message is accurate ;)
Please create your own issue thread listing all of the issues so it鈥檚 not clogging up this thread with unrelated issues. 馃憤馃徎
Cheers.
Will copy the problems I listed as new issue. I issue for all or each one separate?
I have re-read the docs and indeed it clearly says to copy the contents of 'upload' rather than the folder itself - oops!
I think my comment about setup/install still stands. Those two words appearing together in bold with a slash in between says to me to delete folder 'install' inside folder 'setup' but there is no install folder and the intent is really to delete the whole setup folder that was used to do the install. The word install is redundant/irrelevant. (I believe). [As someone who for nearly 50 years has been trying to write clear instructions for users, I tend to be rather sensitive :)]
Anyway, I think the copy/paste issue is solved based on the limited testing I have done.
@LeslieDesser
Create one issue report listing all of your findings.
We will look at this.
Cheers.
Most helpful comment
@balojs
Idk then. All I can say is try attaching the files whilst you wait for the new editor to be implemented.
Another thing I've heard people do is pasting the image until it does actually paste. Meaning, if you paste and it doesn't work, wait until the request finishes and paste again. Repeat this until it actually pastes.
Cheers.