dcasal Posted July 28, 2005 Share Posted July 28, 2005 Hello everybody, A while ago, I noticed that my MediaWiki instance couldn't find any of its images...I checked permissions on the /public_html/wiki/home/images directory and it was 775..I changed that to 777 but it didn't make a difference... Anyone know of a common mistake I might have made? Cheers, David Quote Link to comment Share on other sites More sharing options...
dcasal Posted August 8, 2005 Author Share Posted August 8, 2005 Hello everybody, A while ago, I noticed that my MediaWiki instance couldn't find any of its images...I checked permissions on the /public_html/wiki/home/images directory and it was 775..I changed that to 777 but it didn't make a difference... Anyone know of a common mistake I might have made? <{POST_SNAPBACK}> It looks like not even public_html/index.html can display images in the public_html/images folder, as <img src="images/toad.jpg"></img> in index.html won't work (meaning, the browser won't display it) Anyone have any clue why that might be happening? d Quote Link to comment Share on other sites More sharing options...
TCH-Andy Posted August 8, 2005 Share Posted August 8, 2005 Hi David, Can you give us a link to test? (PM me if you don't want to put it on the open forum) Quote Link to comment Share on other sites More sharing options...
dcasal Posted August 8, 2005 Author Share Posted August 8, 2005 Andy comes to the resque! What a Star. Pesky .htaccess... ;-) d Quote Link to comment Share on other sites More sharing options...
smesser Posted October 12, 2007 Share Posted October 12, 2007 Hi David, Can you give us a link to test? (PM me if you don't want to put it on the open forum) I know this thread is very old but I may or may not be having a similar issue. I have installed a MediaWiki extension that can display uml diagrams. It uses MetaUML, ImageMagick, etc. The problem is that the extension generates a png image on the fly and while rendering the page the extesnion inserts the following code <img src='C:\Apache2\htdocs\wiki\images\math\tmp\uml-03401e206d389c784552fd8765d1d246.png'> Which only displays the unknown gif I believe that the browser doesn't have a permission to the folder. I have tried allowing access, deleting all the .htaccess files (test environment) and between Google and me I can't seem to figure out the issue. Hope you still around. Thanks, Steve Quote Link to comment Share on other sites More sharing options...
TCH-Andy Posted October 12, 2007 Share Posted October 12, 2007 Hi Steve, welcome to the forums Is there anything in the error log ? Are you running this on a windows machine ? I assume also ( from the path you give) that it's the only domain on that server. Is that path correct ? Quote Link to comment Share on other sites More sharing options...
TCH-Thomas Posted October 12, 2007 Share Posted October 12, 2007 Welcome to the forum, Steve. Quote Link to comment Share on other sites More sharing options...
TCH-Bruce Posted October 12, 2007 Share Posted October 12, 2007 Welcome to the forums Steve Quote Link to comment Share on other sites More sharing options...
smesser Posted October 13, 2007 Share Posted October 13, 2007 Hi Steve, welcome to the forums Is there anything in the error log ? Are you running this on a windows machine ? I assume also ( from the path you give) that it's the only domain on that server. Is that path correct ? I assume that you are referring to the Apache log file. If so, no I don't see any errors there. Yes, I am using a Windows setup denoted in my path above "C:\... " I am a programmer and not a network admin so when ask if it's my only domain I don't know what you mean. However, I will tell you what I know. Its just running on a machine on my local home network and its also a Windows Vista machine not viewable to the outside world. I know it has put all kinds of new security stuff it so that could be an issue. I use it to try things out and if I like it I install it at work on an interal use only Wiki. The path is correct and the image it refers to does exist. I attached a small image of what displays when I run the extension. Quote Link to comment Share on other sites More sharing options...
TCH-Andy Posted October 13, 2007 Share Posted October 13, 2007 It sounds as if the URL being produced by mediawiki for that image is incorrect and trying to go to C:\Apache2\htdocs\wiki\images\math\tmp\uml-03401e206d389c784552fd8765d1d246.png Your browser will then be trying to pick up the file from your C drive ( not the c: drive with mediawiki on ). It's tricky to diagnose fully on a machine we have no access - but I'd check your config for that module. Quote Link to comment Share on other sites More sharing options...
smesser Posted October 13, 2007 Share Posted October 13, 2007 It sounds as if the URL being produced by mediawiki for that image is incorrect and trying to go to C:\Apache2\htdocs\wiki\images\math\tmp\uml-03401e206d389c784552fd8765d1d246.png Your browser will then be trying to pick up the file from your C drive ( not the c: drive with mediawiki on ). It's tricky to diagnose fully on a machine we have no access - but I'd check your config for that module. How can the url be incorrect? The path exists the file exists. Does the path need to be relative to the wiki installation instead of an absolute path? Thanks for your comments. Quote Link to comment Share on other sites More sharing options...
TCH-Andy Posted October 13, 2007 Share Posted October 13, 2007 because when you are on the browser on your computer it will take src='C:\Apache2\htdocs\wiki\images\math\tmp\uml-03401e206d389c784552fd8765d1d246.png' And look on your c:\ drive. You need a path that includes the domain name or path by reference usually, so that it can find it on the correct server. Quote Link to comment Share on other sites More sharing options...
smesser Posted October 13, 2007 Share Posted October 13, 2007 because when you are on the browser on your computer it will take src='C:\Apache2\htdocs\wiki\images\math\tmp\uml-03401e206d389c784552fd8765d1d246.png' And look on your c:\ drive. You need a path that includes the domain name or path by reference usually, so that it can find it on the correct server. I finally think I understand. http://localhost/wiki/images/math/tmp/uml.png A link like this works. So I just need to return a url that the browser can understand. Thanks for putting up with my dumb questions. Steve Quote Link to comment Share on other sites More sharing options...
TCH-Andy Posted October 14, 2007 Share Posted October 14, 2007 You're welcome The only dumb question is one that isn't asked. And yes, a path including the host should work ( although localhost usually means your own machine - so will work if you are actually on the machine that is acting as the web server ) Quote Link to comment Share on other sites More sharing options...
smesser Posted October 14, 2007 Share Posted October 14, 2007 You're welcome The only dumb question is one that isn't asked. And yes, a path including the host should work ( although localhost usually means your own machine - so will work if you are actually on the machine that is acting as the web server ) Yeah, I ended up using something like $serverURL = 'http://' . $_SERVER['SERVER_ADDR'] . '/wiki/images/math/tmp'; which works so now I can tweak it to where ever I want. Thanks again for your input. Quote Link to comment Share on other sites More sharing options...
TCH-Andy Posted October 14, 2007 Share Posted October 14, 2007 You're welcome I'm glad it's all sorted. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.