Bug #54671
Neos 1.0.1 Media preview not showing up with .png file
Status: | Closed | Start date: | 2014-01-01 | |
---|---|---|---|---|
Priority: | Must have | Due date: | ||
Assigned To: | - | % Done: | 0% |
|
Category: | - | |||
Target version: | - |
Description
With a fresh install of Neos 1.0.1 and a new empty site created
I uploaded a .png file with the help of Media Management in Neos backend GUI.
The preview of the image is broken.
-> Please see attached screenshot.
History
#1 Updated by Chr is over 1 year ago
Same problem with JPG file.
Seems to be a general problem, no matter which file/image type.
#2 Updated by Chr is over 1 year ago
Webserver error log contains this error message:
File does not exist: /path/to/htdocs/_Resources/Persistent/b493f74e55a87a565ab769e6162759a13ff3df40.jpg/NeosMediaPreviewBug.jpg
(and another one for the png file)
#3 Updated by Chr is over 1 year ago
The files actually are available on the server:
user@server:/path/to/htdocs/_Resources/Persistent$ ll total 0 lrwxrwxrwx 1 user group 130 Jan 1 17:27 55ff84250b80b470a477b6508e3b0d99915d5782.jpg -> /path/to/TYPO3-Neos/Data/Persistent/Resources/55ff84250b80b470a477b6508e3b0d99915d5782 lrwxrwxrwx 1 user group 130 Jan 1 17:27 75e9bb6737065fecbb6de92a3b021638330fa389.jpg -> /path/to/TYPO3-Neos/Data/Persistent/Resources/75e9bb6737065fecbb6de92a3b021638330fa389 lrwxrwxrwx 1 user group 130 Jan 1 17:10 97b5ff3fadf4d4eaa62d7fa6608a04aad8ceaa2f.png -> /path/to/TYPO3-Neos/Data/Persistent/Resources/97b5ff3fadf4d4eaa62d7fa6608a04aad8ceaa2f lrwxrwxrwx 1 user group 130 Jan 1 17:08 a44347cd077a49716f209531f332e2bbe1a9af14.png -> /path/to/TYPO3-Neos/Data/Persistent/Resources/a44347cd077a49716f209531f332e2bbe1a9af14 lrwxrwxrwx 1 user group 130 Jan 1 17:29 b493f74e55a87a565ab769e6162759a13ff3df40.jpg -> /path/to/TYPO3-Neos/Data/Persistent/Resources/b493f74e55a87a565ab769e6162759a13ff3df40 lrwxrwxrwx 1 user group 130 Jan 1 17:29 e1d4171939920e0a27d85eb3f0de1d2fe2ef889f.png -> /path/to/TYPO3-Neos/Data/Persistent/Resources/e1d4171939920e0a27d85eb3f0de1d2fe2ef889f
user@server:/path/to/htdocs/_Resources/Persistent$ ll /path/to/TYPO3-Neos/Data/Persistent/Resources/ total 80 -rw-r--r-- 1 user group 5313 Jan 1 17:27 55ff84250b80b470a477b6508e3b0d99915d5782 -rw-r--r-- 1 user group 19765 Jan 1 17:27 75e9bb6737065fecbb6de92a3b021638330fa389 -rw-r--r-- 1 user group 10091 Jan 1 17:08 97b5ff3fadf4d4eaa62d7fa6608a04aad8ceaa2f -rw-r--r-- 1 user group 30002 Jan 1 17:08 a44347cd077a49716f209531f332e2bbe1a9af14 -rw-r--r-- 1 user group 905 Jan 1 17:29 b493f74e55a87a565ab769e6162759a13ff3df40 -rw-r--r-- 1 user group 1158 Jan 1 17:29 e1d4171939920e0a27d85eb3f0de1d2fe2ef889f
Note: user and group are those the webserver is run under. It is a shared hosting environment with PHP via FastCGI. Each hosting package has it's own virtual host.
#4 Updated by Stéphane Wecker over 1 year ago
Same issue here with PHP / nginx.
With or without the rewrite rule :
location ~ "^/_Resources/Persistent/" {
rewrite "^(_Resources/Persistent/.{40})/.+(\..+)" /$1$2 break;
}
#5 Updated by Chr is over 1 year ago
When drag-and-dropping an image into Neos backend's Media Management
a symbolic link is generated in directory /path/to/webroot/_Resources/Persistent/:
user@server: ll /path/to/webroot/_Resources/Persistent/ lrwxrwxrwx 1 user group 130 Feb 20 21:30 a9589a0228b463588d15daa66a356ac166ee59c4 -> /path/to/TYPO3-Neos/Data/Persistent/Resources/a9589a0228b463588d15daa66a356ac166ee59c4
Is this the default behaviour?
Neos backend's Media Management wants to display the URL...
http://example.com/_Resources/Persistent/a9589a0228b463588d15daa66a356ac166ee59c4/image-file.png
...and Webserver error log reports:
File does not exist: /path/to/htdocs/_Resources/Persistent/a9589a0228b463588d15daa66a356ac166ee59c4/image-file.png
Whereas opening the URL...
http://example.com/_Resources/Persistent/*a9589a0228b463588d15daa66a356ac166ee59c4
...works just fine and displays the image correctly!
-> Might there be a problem with RewriteRules with shipped .htaccess ???
#6 Updated by Christian Müller over 1 year ago
- Status changed from New to Needs Feedback
Do the RewriteRules work for other Images in the Neos instances? Like the existing images in the demo site? They all exist only with their hash without any extension. I cannot reproduce the problem at all on my machine so maybe it was something in the Media management that was fixed in master. Could you check if it is fixed for you as well on dev-master?
#7 Updated by Chr is about 1 year ago
The same issue persists in Neos 1.1 - so I guess this problem exists as well in dev-master?!
I did not install the shipped Demo Site, so I can't tell if the problem exists there as well.
To sum it up again:
Fresh installation of Neos 1.1
Drag & Dropping Images into Media Managament in Neos backend.
-> Images' previews are displayed as "broken image symbol"
Adding any image to a page results in "broken image symbol" on the webpage in frontend as well.
Image-URL used on the website (= frontend)
and in Media Preview in Media Management (backend):
http://example.com/_Resources/Persistent/<HASH>/RealFilename.png
However - calling this URL manually in Browser brings up the image just fine:
#8 Updated by Christian Müller about 1 year ago
OK, this certainly is a server/configuration problem. Which http server are you using?
If it is apache see .htaccess line 54. This is important for the resource URLs to work. Maybe try to set it globally as well.
#9 Updated by Chr is about 1 year ago
We use an Apache Webserver.
Thx for the pointer!
You meant the .htaccess-file living in TYPO3-Neos/Web/
At the very end there are these lines:
# prevents Apache's automatic file negotiation, it breaks resource URLs # Options -MultiViews
As you can see I needed to comment out the line where MultiViews is disabled.
This is because leaving it as-is lead to a Server Error 500.
My Hoster put some of the webserver's settings to the customer's backend.
I found this option after digging deeper after you said that it would be a definite server configuration problem.
From my point of view this issue #54671 can be closed.
#10 Updated by Christian Müller about 1 year ago
- Status changed from Needs Feedback to Closed