Bug #33377
closed
Javascript error: URI malformed when adding new sections
Added by joujou no-lastname-given almost 13 years ago.
Updated over 12 years ago.
Category:
Backend User Interface
Description
With Typo3 4.5.10, I have a javascript error "URI malformed" when adding new parameters in the "media" tab of the media content element or when adding new sections in a FCE.
I have websites that share the same sources with symbolic links, it works with some of them and I have the bug with some others.
In a multi-domain installation, it works for the first domain and it doesn't work for the others.
Files
js-error.jpg (45.1 KB)
js-error.jpg |
Js Error when adding parameters in media content / media tab |
joujou no-lastname-given, 2012-01-24 11:00
|
|
- Status changed from New to Needs Feedback
This is indeed strange, as it seems to work in my installations. Potential causes might be:
- Some extension installed in particular sites which XCLASS some fundamental TYPO3 core class and "breaks" it (check by uninstalling the extensions one by one, until it "works")
- If the "multi-domain" issue is indeed the cause of the problem, it might be interesting for us to know in which exact situation do you see the error and what do you call "multi-domain" exactly (please give an example setup and a "how to reproduce" information).
What I call multi-domain is an install with n sites in the same database, each site root page having a domain record associated.
Strangely, it works now in this installation.
I have another installation, with several sites, each one having its own database, sharing the same sources.
For 1 site, it bugs in the media content, showing what there's in the screenshot I've attached (when I click to add parameters or custom parameters).
For another one, it works with the media content but it produces the error in a FCE in which it's possible to add sections.
After checking extensions in each site and trying to uninstall some, I still have the problem.
Ok, I progress: it's in relation with translation of the backend or special characters (accents).
My backend is in french and when I desactivate and come back to english, everything is ok.
Yes, that might be the problem indeed.
Please try out the fix proposed in https://review.typo3.org/7468.
If it works for you, give your "+1" on verification, maybe mentioning your issue #33377. If this is really the case, we can close your issue and mark it as "duplicate" for #32238, ok?
Thanks!
Sorry but I'm ridiculously unable to fetch the fix, I don't know how to do that...Do I need a special client program to fetch it ?
I've used the diff of the patch and I've modified t3lib/class.t3lib_tceforms.php, removing unescape(). I've checked in the source code of the backend page, it's removed, yet I still have the bug.
- Status changed from Needs Feedback to Accepted
- Complexity set to medium
The problem only happens in sites which are not running with UTF-8 (not "forceCharset=utf8"). The french backend is rendered in charset=iso-8859-1. This used to work well with "unescape()". The fix from #28952 added the decodeURIComponent() call. Fix #28952 will remove the (superfluous) unescape(). But this will only solve it for UTF-8 backends.
For non-UTF-8 backends I have currently no idea on how to solve this. In my quick research I stumbled over this resource:
http://xkr.us/articles/javascript/encode-compare/
As we want to still support non-UTF-8 charsets in 4.5 LTS, we should try to find a solution that works well in both situations.
For your particular situation, you might consider converting your database and site to UTF-8, which is recommended anyway.
That's what I was trying to do: migrating to UTF8 but it's not simple.
Up to now, I haven't found a better solution:
- desactivate the backend translation and come back to english as the backend langage
OR
- migrate Typo3 + DB to UTF8 (not so hard finally)
If you are not affected by issue #28952 you can fix this bug by rolling back the change from #28952 (remove the call to decodeURIComponent)
Closing this one in favor of #34330
- Status changed from Accepted to Closed
Also available in: Atom
PDF