Not logged in. · Lost password · Register
Forum: General Discussion Features and Functionality RSS
Images aren't Visible. Any Idea?
some help would much appreciated
leftdick #1
Member for 3 months · 3 posts
Group memberships: Members
Show profile · Link to this post
Subject: Images aren't Visible. Any Idea?
Hello Folks,

I have installed DokuWiki on a server where I pay to run my photoblog. Big thanks for it, looks like a great Wiki and I would like to use it in my work, too. Thus, I would like to test it out now.

I could install it next to my photoblog and runs well. I spent some hours to create namespaces and pages and played around with templates etc.

However somehow I cannot get DokuWiki to display ANY images in any browser (IE, FireFox). Even when I go to to the section wiki:dokuwiki the little picture isn't visible, as you can see it below.

Could anyone tell me please, why? I have tried to upload various images (.JPG, .PNG etc.) to an "images" namespace, too but the result is not too happy either. ...

Please leave some comment! Thanks a lot in anticipation,

Left

[Image: http://latitude.hu/image_1.JPG]
Avatar
chi (Moderator) #2
Member since Jun 2006 · 775 posts · Location: Munich Germany
Group memberships: Global Moderators, Members
Show profile · Link to this post
Have you tried to access the images directly (via a URL)?
Please add [SOLVED] to the initial thread subject if you feel your question has been answered.
leftdick #3
Member for 3 months · 3 posts
Group memberships: Members
Show profile · Link to this post
Hi chi,

Yes, I have tried it. Right-click on the properties of the "image" (which is not visible), and the URL goes:

"www.latitude.hu/WIKI2/lib/exe/fetch.php?w=&h=&cache=cache&media=wiki:dokuwiki-128.png"

I suppose there might be something with the fetch.php, but could not find out what....

Hope this gives you an idea!

Cheers,

Left
Avatar
chi (Moderator) #4
Member since Jun 2006 · 775 posts · Location: Munich Germany
Group memberships: Global Moderators, Members
Show profile · Link to this post
Quote by leftdick:
Hi chi,

Yes, I have tried it. Right-click on the properties of the "image" (which is not visible), and the URL goes:

"www.latitude.hu/WIKI2/lib/exe/fetch.php?w=&h=&cache=cache&media=wiki:dokuwiki-128.png"

Well, the error you get when you follow that link is quite obvious:

Not Found

The requested URL /WIKI2/lib/exe/fetch.php was not found on this server.

Could you check if the fetch.php is actually there?
Please add [SOLVED] to the initial thread subject if you feel your question has been answered.
leftdick #5
Member for 3 months · 3 posts
Group memberships: Members
Show profile · Link to this post
yeah, I've checked that, it's there alright.

Just thinking, maybe it is write-protected? I cannot check it right now, since I'm at work...

Might has something to do with ther server where it is installed on, however I'm just only paying for those guys to host my photoblog, so I don't have too much control over it.

I might need to install DokuWiki it on another server to test it.

But thanks for the help anyways, much appreciated!

Left
tedr #6
Member for 2 months · 1 post
Group memberships: Members
Show profile · Link to this post
Subject: Have the same problem I believe
 We have the same problem I believe. Image files upload, but the display syntax does not work, though the images are uploaded and web accessible.

For example the default syntax will not display an image

e.g. {{image_name.jpg}}

But if I post the absolute path to the file that was uploaded to dokuwiki, the image displays fine:

e.g. {{http://www.domain.com/wiki/data/media/image_name.png}}

If I try and view the image using the magnifying glass when the 'Media Files' window is open I get this error

"The image “http://don.dogster.com/wiki/lib/exe/fetch.php?media=image_name.png” cannot be displayed, because it contains errors."
But no php errors are output to log.

Here are a couple other facts.

*All uploaded image files are chmod 777 and the /data/media folder is also 777
*fetch.php is 644
*We're using the 2008-05-05 version.

We've been real stumped on this one. It's fine we can modify the path by hand and have images appear, but it's a bit of a challenge for our non-technical members to get it right.
jheckmann #7
Member for 3 months · 15 posts
Group memberships: Members
Show profile · Link to this post
I have this same problem.

The Media Manager uploads images just fine; they can be accessed and viewed outside of the wiki.  I get the same error using the magnifier in Media Manager.

I deleted all files in /data/cache, except _dummy of course, but that didn't help.
Avatar
andi (Administrator) #8
Member since May 2006 · 747 posts · Location: Berlin Germany
Group memberships: Administrators, Members
Show profile · Link to this post
Did you set any of the xsendfile options without support for it in your Webserver?

Otherwise try to download such an image with wget or curl, then have a look at the downloaded content.
Read this if you don't get any useful answers.
jheckmann #9
Member for 3 months · 15 posts
Group memberships: Members
Show profile · Link to this post
Xsendfile options in Configuration Manager are untouched.

Binary download - images look just fine.  Display perfectly in Firefox from an .html page with <img> tags, created in the same directory as doku.php.

I use the DokuWiki syntax page as my test; dokuwiki-128.png is supposed to appear several times on that page.  The images appeared when DokuWiki was first installed; now they no longer appear.  Right click where the image should be, display in new tab, get the detail page for the image but the image is not displayed, just a link.  Interesting - on reload of this detail page, Firefox briefly displays a broken image box in place of the link, then immediately it goes away and is replaced by the link.

While setting up DokuWiki in a local development environment (EasyPHP on XP), this problem happened again.  The syntax page images were displayed at first, now they're not displayed anymore.  Clearing browser cache, /data/cache, forcing the page to reload, nothing helps. 

While researching this problem I came across a Mozilla bug report for the same message (cannot be displayed... contains errors).  Nothing was wrong with the images they used to test.  It was a caching problem with the browser, which was fixed (quite awhile ago).  They followed a very methodical process to narrow down and reproduce the problem.  FWIW:  https://bugzilla.mozilla.org/show_bug.cgi?id=121084.  A brief description:

Sometimes images aren't displayed on their prospective pages, and when I right click on the image and go to "display image" it gives me a message with the following error message.
- The image "[image name]" cannot be displayed because it contains errors. What can I do?
This is a known bug that is being worked on. The image itself is fine, i.e. it contains no errors.
The reason for this behavior appears to be the fact that Mozilla - depending on your Cache settings - requests the image twice. It only appears on websites that do not allow images to be linked to/called directly from outside of their pages. Since Mozilla does not send the referrer (i.e. web address of the page where the file is linked from) the second time it requests the image, the website sends an "access denied" page in HTML form where Mozilla is expecting an image, hence the error messsage (Mozilla tries to display an image when it receives an HTML page, so for the browser, the "image" contains an error).  Solution: Change your cache settings to "Compare the page in the cache to the page on the network When the page is out of date". To do so, select "Edit" -> "Preferences" -> "Advanced" -> "Cache". 

Makes me wonder if DokuWiki is doing something similar?

I've spent days trying to figure this out.  I initially liked DokuWiki.  Now I'm about ready to give it up.  It's just not worth this much of my time, and trying to find an answer or even a path to follow to debug this in the manual or the forums seems more difficult than it should be.
jheckmann #10
Member for 3 months · 15 posts
Group memberships: Members
Show profile · Link to this post
Looking at the apache access.log in the local development environment, would this seem to indicate that when the page syntax.txt loads, the image dokuwiki-128.png is found successfully and cached (206 first time), found successfully on refresh (200 second time)?  Which would rule out permission problems, images missing... seems to narrow it down to images processed via fetch.php are missing (other images display ok).

127.0.0.1 - - [14/Jul/2008:10:03:49 -0400] "GET /avidflyerwiki/ HTTP/1.1" 302 -
127.0.0.1 - - [14/Jul/2008:10:03:49 -0400] "GET /avidflyerwiki/doku.php HTTP/1.1" 200 17265
127.0.0.1 - - [14/Jul/2008:10:03:51 -0400] "GET /avidflyerwiki/lib/tpl/monobook/common/print.css HTTP/1.1" 200 1047
127.0.0.1 - - [14/Jul/2008:10:03:51 -0400] "GET /avidflyerwiki/lib/exe/indexer.php?id=start&1216044231 HTTP/1.1" 200 45
127.0.0.1 - - [14/Jul/2008:10:03:58 -0400] "GET /avidflyerwiki/doku.php?id=wiki:admin:dokuwiki HTTP/1.1" 200 15402
127.0.0.1 - - [14/Jul/2008:10:03:59 -0400] "GET /avidflyerwiki/lib/exe/indexer.php?id=wiki%3Aadmin%3Adokuwiki&1216044239 HTTP/1.1" 200 45
127.0.0.1 - - [14/Jul/2008:10:04:04 -0400] "GET /avidflyerwiki/doku.php?id=wiki:syntax HTTP/1.1" 200 59021
127.0.0.1 - - [14/Jul/2008:10:04:05 -0400] "GET /avidflyerwiki/lib/exe/fetch.php?w=&h=&cache=cache&media=wiki:dokuwiki-128.png HTTP/1.1" 206 32771
127.0.0.1 - - [14/Jul/2008:10:04:06 -0400] "GET /avidflyerwiki/lib/exe/fetch.php?w=50&h=&cache=cache&media=wiki:dokuwiki-128.png HTTP/1.1" 206 6489
127.0.0.1 - - [14/Jul/2008:10:04:06 -0400] "GET /avidflyerwiki/lib/exe/fetch.php?w=200&h=50&cache=cache&media=wiki:dokuwiki-128.png HTTP/1.1" 206 19094
127.0.0.1 - - [14/Jul/2008:10:04:07 -0400] "GET /avidflyerwiki/lib/exe/indexer.php?id=wiki%3Asyntax&1216044245 HTTP/1.1" 200 45
127.0.0.1 - - [14/Jul/2008:10:04:20 -0400] "GET /avidflyerwiki/doku.php?id=wiki:syntax HTTP/1.1" 200 59021
127.0.0.1 - - [14/Jul/2008:10:04:21 -0400] "GET /avidflyerwiki/lib/exe/css.php?s=all&t=monobook HTTP/1.1" 200 3817
127.0.0.1 - - [14/Jul/2008:10:04:22 -0400] "GET /avidflyerwiki/lib/exe/css.php?t=monobook HTTP/1.1" 200 16099
127.0.0.1 - - [14/Jul/2008:10:04:22 -0400] "GET /avidflyerwiki/lib/exe/css.php?s=print&t=monobook HTTP/1.1" 200 10064
127.0.0.1 - - [14/Jul/2008:10:04:23 -0400] "GET /avidflyerwiki/lib/exe/js.php?edit=0&write=0 HTTP/1.1" 200 63266
127.0.0.1 - - [14/Jul/2008:10:04:24 -0400] "GET /avidflyerwiki/lib/tpl/monobook/common/wikibits.js HTTP/1.1" 200 23066
127.0.0.1 - - [14/Jul/2008:10:04:24 -0400] "GET /avidflyerwiki/lib/tpl/monobook/user/favicon.ico HTTP/1.1" 200 742
127.0.0.1 - - [14/Jul/2008:10:04:24 -0400] "GET /avidflyerwiki/lib/tpl/monobook/monobook/main.css HTTP/1.1" 200 25027
127.0.0.1 - - [14/Jul/2008:10:04:24 -0400] "GET /avidflyerwiki/lib/tpl/monobook/common/print.css HTTP/1.1" 200 1047
127.0.0.1 - - [14/Jul/2008:10:04:24 -0400] "GET /avidflyerwiki/lib/tpl/monobook/common/commonPrint.css HTTP/1.1" 200 5567
127.0.0.1 - - [14/Jul/2008:10:04:24 -0400] "GET /avidflyerwiki/lib/tpl/monobook/dokuwiki/doku.css HTTP/1.1" 200 7527
127.0.0.1 - - [14/Jul/2008:10:04:24 -0400] "GET /avidflyerwiki/lib/tpl/monobook/lang/en/lang.css HTTP/1.1" 200 -
127.0.0.1 - - [14/Jul/2008:10:04:24 -0400] "GET /avidflyerwiki/lib/tpl/monobook/user/Common.css HTTP/1.1" 200 -
127.0.0.1 - - [14/Jul/2008:10:04:24 -0400] "GET /avidflyerwiki/lib/tpl/monobook/wikipedia/en/Common.css HTTP/1.1" 200 14342
127.0.0.1 - - [14/Jul/2008:10:04:24 -0400] "GET /avidflyerwiki/lib/tpl/monobook/wikipedia/en/Monobook.css HTTP/1.1" 200 7605
127.0.0.1 - - [14/Jul/2008:10:04:24 -0400] "GET /avidflyerwiki/lib/tpl/monobook/dokuwiki/button-dw.png HTTP/1.1" 200 3459
127.0.0.1 - - [14/Jul/2008:10:04:24 -0400] "GET /avidflyerwiki/lib/tpl/monobook/dokuwiki/button-rss.png HTTP/1.1" 200 280
127.0.0.1 - - [14/Jul/2008:10:04:24 -0400] "GET /avidflyerwiki/lib/tpl/monobook/dokuwiki/button-mb.png HTTP/1.1" 200 3560
127.0.0.1 - - [14/Jul/2008:10:04:24 -0400] "GET /avidflyerwiki/lib/tpl/monobook/dokuwiki/button-xhtml.png HTTP/1.1" 200 321
127.0.0.1 - - [14/Jul/2008:10:04:24 -0400] "GET /avidflyerwiki/lib/tpl/monobook/dokuwiki/button-css.png HTTP/1.1" 200 299
127.0.0.1 - - [14/Jul/2008:10:04:24 -0400] "GET /avidflyerwiki/lib/tpl/monobook/dokuwiki/button-php.gif HTTP/1.1" 200 269
127.0.0.1 - - [14/Jul/2008:10:04:25 -0400] "GET /avidflyerwiki/lib/tpl/monobook/user/Monobook.css HTTP/1.1" 200 -
127.0.0.1 - - [14/Jul/2008:10:04:25 -0400] "GET /avidflyerwiki/lib/images/smileys/icon_cool.gif HTTP/1.1" 200 172
127.0.0.1 - - [14/Jul/2008:10:04:25 -0400] "GET /avidflyerwiki/lib/images/smileys/icon_eek.gif HTTP/1.1" 200 170
127.0.0.1 - - [14/Jul/2008:10:04:25 -0400] "GET /avidflyerwiki/lib/images/smileys/icon_sad.gif HTTP/1.1" 200 171
127.0.0.1 - - [14/Jul/2008:10:04:25 -0400] "GET /avidflyerwiki/lib/images/smileys/icon_smile.gif HTTP/1.1" 200 174
127.0.0.1 - - [14/Jul/2008:10:04:25 -0400] "GET /avidflyerwiki/lib/images/smileys/icon_smile2.gif HTTP/1.1" 200 174
127.0.0.1 - - [14/Jul/2008:10:04:25 -0400] "GET /avidflyerwiki/lib/images/smileys/icon_doubt.gif HTTP/1.1" 200 990
127.0.0.1 - - [14/Jul/2008:10:04:26 -0400] "GET /avidflyerwiki/lib/images/smileys/icon_doubt2.gif HTTP/1.1" 200 992
127.0.0.1 - - [14/Jul/2008:10:04:26 -0400] "GET /avidflyerwiki/lib/images/smileys/icon_confused.gif HTTP/1.1" 200 171
127.0.0.1 - - [14/Jul/2008:10:04:26 -0400] "GET /avidflyerwiki/lib/images/smileys/icon_biggrin.gif HTTP/1.1" 200 172
127.0.0.1 - - [14/Jul/2008:10:04:26 -0400] "GET /avidflyerwiki/lib/images/smileys/icon_razz.gif HTTP/1.1" 200 176
127.0.0.1 - - [14/Jul/2008:10:04:26 -0400] "GET /avidflyerwiki/lib/images/smileys/icon_surprised.gif HTTP/1.1" 200 174
127.0.0.1 - - [14/Jul/2008:10:04:26 -0400] "GET /avidflyerwiki/lib/images/smileys/icon_silenced.gif HTTP/1.1" 200 231
127.0.0.1 - - [14/Jul/2008:10:04:26 -0400] "GET /avidflyerwiki/lib/images/smileys/icon_neutral.gif HTTP/1.1" 200 171
127.0.0.1 - - [14/Jul/2008:10:04:26 -0400] "GET /avidflyerwiki/lib/images/smileys/icon_wink.gif HTTP/1.1" 200 170
127.0.0.1 - - [14/Jul/2008:10:04:26 -0400] "GET /avidflyerwiki/lib/images/smileys/icon_fun.gif HTTP/1.1" 200 590
127.0.0.1 - - [14/Jul/2008:10:04:26 -0400] "GET /avidflyerwiki/lib/images/smileys/icon_question.gif HTTP/1.1" 200 248
127.0.0.1 - - [14/Jul/2008:10:04:26 -0400] "GET /avidflyerwiki/lib/images/smileys/icon_exclaim.gif HTTP/1.1" 200 236
127.0.0.1 - - [14/Jul/2008:10:04:26 -0400] "GET /avidflyerwiki/lib/images/smileys/icon_lol.gif HTTP/1.1" 200 336
127.0.0.1 - - [14/Jul/2008:10:04:27 -0400] "GET /avidflyerwiki/lib/images/smileys/fixme.gif HTTP/1.1" 200 1435
127.0.0.1 - - [14/Jul/2008:10:04:27 -0400] "GET /avidflyerwiki/lib/images/smileys/delete.gif HTTP/1.1" 200 1421
127.0.0.1 - - [14/Jul/2008:10:04:27 -0400] "GET /avidflyerwiki/lib/tpl/monobook/monobook/headbg.jpg HTTP/1.1" 200 7881
127.0.0.1 - - [14/Jul/2008:10:04:27 -0400] "GET /avidflyerwiki/lib/tpl/monobook/monobook/bullet.gif HTTP/1.1" 200 50
127.0.0.1 - - [14/Jul/2008:10:04:27 -0400] "GET /avidflyerwiki/lib/images/interwiki/doku.gif HTTP/1.1" 200 257
127.0.0.1 - - [14/Jul/2008:10:04:27 -0400] "GET /avidflyerwiki/lib/images/interwiki/wp.gif HTTP/1.1" 200 680
127.0.0.1 - - [14/Jul/2008:10:04:27 -0400] "GET /avidflyerwiki/lib/images/interwiki/dokubug.gif HTTP/1.1" 200 166
127.0.0.1 - - [14/Jul/2008:10:04:27 -0400] "GET /avidflyerwiki/lib/tpl/monobook/user/logo.png HTTP/1.1" 200 7843
127.0.0.1 - - [14/Jul/2008:10:04:27 -0400] "GET /avidflyerwiki/lib/tpl/monobook/monobook/user.gif HTTP/1.1" 200 932
127.0.0.1 - - [14/Jul/2008:10:04:27 -0400] "GET /avidflyerwiki/lib/plugins/gallery/images/loading.gif HTTP/1.1" 200 2230
127.0.0.1 - - [14/Jul/2008:10:04:27 -0400] "GET /avidflyerwiki/lib/plugins/gallery/images/expand.gif HTTP/1.1" 200 209
127.0.0.1 - - [14/Jul/2008:10:04:27 -0400] "GET /avidflyerwiki/lib/plugins/gallery/images/close.gif HTTP/1.1" 200 99
127.0.0.1 - - [14/Jul/2008:10:04:27 -0400] "GET /avidflyerwiki/lib/plugins/gallery/images/next.gif HTTP/1.1" 200 93
127.0.0.1 - - [14/Jul/2008:10:04:27 -0400] "GET /avidflyerwiki/lib/plugins/gallery/images/prev.gif HTTP/1.1" 200 94
127.0.0.1 - - [14/Jul/2008:10:04:27 -0400] "GET /avidflyerwiki/lib/tpl/monobook/monobook/external.png HTTP/1.1" 200 165
127.0.0.1 - - [14/Jul/2008:10:04:27 -0400] "GET /avidflyerwiki/lib/tpl/monobook/dokuwiki/tocdot2.gif HTTP/1.1" 200 810
127.0.0.1 - - [14/Jul/2008:10:04:24 -0400] "GET /avidflyerwiki/lib/exe/fetch.php?w=200&h=50&cache=cache&media=wiki:dokuwiki-128.png HTTP/1.1" 200 19094
127.0.0.1 - - [14/Jul/2008:10:04:25 -0400] "GET /avidflyerwiki/lib/exe/indexer.php?id=wiki%3Asyntax&1216044261 HTTP/1.1" 200 45
127.0.0.1 - - [14/Jul/2008:10:04:25 -0400] "GET /avidflyerwiki/lib/exe/fetch.php?w=&h=&cache=cache&media=wiki:dokuwiki-128.png HTTP/1.1" 200 32771
127.0.0.1 - - [14/Jul/2008:10:04:24 -0400] "GET /avidflyerwiki/lib/exe/fetch.php?w=200&h=50&cache=cache&media=http%3A%2F%2Fde3.php.net%2Fimages%2Fphp.gif HTTP/1.1" 302 3
127.0.0.1 - - [14/Jul/2008:10:04:25 -0400] "GET /avidflyerwiki/lib/exe/fetch.php?w=50&h=&cache=cache&media=wiki:dokuwiki-128.png HTTP/1.1" 200 6489
Avatar
andi (Administrator) #11
Member since May 2006 · 747 posts · Location: Berlin Germany
Group memberships: Administrators, Members
Show profile · Link to this post
Quote by jheckmann on 2008-07-14, 17:10:
Looking at the apache access.log in the local development environment, would this seem to indicate that when the page syntax.txt loads, the image dokuwiki-128.png is found successfully and cached (206 first time), found successfully on refresh (200 second time)?  Which would rule out permission problems, images missing... seems to narrow it down to images processed via fetch.php are missing (other images display ok).

This is really strange, lets have a filtered look at your log:

127.0.0.1 - - [14/Jul/2008:10:04:05 -0400] "GET /avidflyerwiki/lib/exe/fetch.php?w=&h=&cache=cache&media=wiki:dokuwiki-128.png HTTP/1.1" 206 32771
127.0.0.1 - - [14/Jul/2008:10:04:25 -0400] "GET /avidflyerwiki/lib/exe/fetch.php?w=&h=&cache=cache&media=wiki:dokuwiki-128.png HTTP/1.1" 200 32771

The thing I find strange is the 206 status code you get on the first request.  RFC 2616 says this is a partial answer. But look at the bytes transfered. It's exactly the same for the 206 and the 200 answer. So why did the browser do a partial request if it was missing *all* bytes?

jheckman, could you give me access to that wiki? Also what web server, PHP, OS and browser(s) do you you use?

Andi
Read this if you don't get any useful answers.
Avatar
andi (Administrator) #12
Member since May 2006 · 747 posts · Location: Berlin Germany
Group memberships: Administrators, Members
Show profile · Link to this post
Okay I got the problem. When looking a the downloaded image file, the first three bytes are a UTF-8 Byte Order Mark. One of your DokuWiki files (probably fetch.php itself or one of the involved configfiles) got corrupted when editing it with a text editor.

You need to load those files in a UTF-8 capable text editor and save them again without a BOM. See http://wiki.splitbrain.org/wiki:utf8#editing_files
Read this if you don't get any useful answers.
jheckmann #13
Member for 3 months · 15 posts
Group memberships: Members
Show profile · Link to this post
Andi, you're absolutely correct.

I did a complete reinstall of Dokuwiki, installed notepad2 on my Windows XP Pro per the link you provided, and opened, encoded and saved every file I had created or changed.  All but one of these opened as ANSI - lang.php in /inc/en/ opened as UTF-8 with signature (BOM).

I replaced this re-encoded lang.php in the old install, and the images appeared.

I sincerely hope this helps someone else whose images are not displaying.

Thank you, Andi.

PS  Here is a useful tool, paste a URL into it and it will tell you whether a BOM is present in the page:
http://people.w3.org/rishida/utils/bomtester/index.php
I hope this is helpful.
This post was edited on 2008-07-31, 16:09 by jheckmann.
Close Smaller – Larger + Reply to this post:
Verification code: VeriCode Please note the verification code from the picture into the text field next to it.
Smileys: :-) ;-) :-D :-p :blush: :cool: :rolleyes: :huh: :-/ <_< :-( :'( :#: :scared: 8-( :nuts: :-O
Special characters:
Go to forum
Imprint
This board is powered by the Unclassified NewsBoard software, 1.6.4, © 2003-7 by Yves Goergen
Current time: 2008-08-21, 21:12:21 (UTC +02:00)
WikiForumIRCBugsTranslate