Opened 9 years ago
Closed 9 years ago
#1141 closed defect (bug) (invalid)
Impossible to upload the subtitles files
Reported by: | Xtraboy | Owned by: | iandunn |
---|---|---|---|
Milestone: | Priority: | normal | |
Component: | WordPress.tv | Keywords: | |
Cc: |
Description
Me and other people having trouble to upload the subtitles .ttml files via form on the website, using Google Chrome, Firefox IE and other browsers.
We are receiving abstract error messages and no informations about why we can't upload our translations or maybe something is wrong with the file.
“Unknown error. Please try again later.”
Attachments (1)
Change History (8)
#2
@
9 years ago
This was the video: http://wordpress.tv/subtitle/?video=46259
And the file translated by my friend @nicolamustone now is attached to this ticket.
#3
@
9 years ago
- Owner set to iandunn
- Status changed from new to assigned
I was able to reproduce the error with that file, thanks :)
#4
@
9 years ago
It looks like VideoPress is rejecting the file because it's not valid TTML. Specifically, there are two problems:
- Entities like
ù
don't exist in TTML (because it's a subset of XML), only in HTML. You can use the character itself and it should be fine, though. - Line 46 has
`
which doesn't exist, it looks like it was maybe a typo? Just like above, it should use the actual character, rather than an entity.
Was the file generated by Amara, or some other method?
#5
@
9 years ago
Hi,
the file is generated with Sublime Text, i simply opened it with the editor, translated it and saved with a new file name. I used the HTML escaped characters because my keyboard is en_UK so i don't have italian chars.
So if i remove those chars it will work, right?
#6
@
9 years ago
It should, yeah.
There are several ways to input those characters without switching your keyboard layout, like typing the Unicode value with some control keys, or using an applet to copy/paste them, etc. The methods vary depending on your OS, text editor and preferences, but searching should turn up lots of options.
I wasn't able to reproduce that; can you upload one of your files to this ticket so I can test with it?
That error happens when the call to WordPressTV_Subtitles_Upload ::handle_upload() results in a WP_Error, which happens when there's an invalid file name, when wp_handle_upload() tries to upload the file, or when the Media Library entry is created.