Hi all,
I don't know why but I can't see images stored in my moodledata folder.
I see list of my files but if I click on them It seems the server can't find them. It don't display images.
Help me please. Tnx
Thank you Michael for answer... I'm sorry for my bad english.
Instead of them I see only a border with a "x" at top left.
------------
|x |
| |
| |
------------
It seems images are not found but in "Site files" they are listed!
I've tried and I restarted webserver (apache 2) but nothing...
My images file are shurely correct because if I put them in the webroot I can see them by url directly. It seems my problem is the moodledata folder.
My file.php file have no empty lines at the beginning.
I'm using Moodle 1.8.2.
For error log.... do you refer to httpd/error.log?
Thank you for help me and for patience for my perfect english!
It's an internal site... anyway...
Did you place your images by copying directly into your moodledata folder or using Files > Upload Files?
mmmm.... .
Right-click on image link from FrontPage > Site Files.... Save object as...
Double-click on the "image" saved and.... "No preview available".
File spok.jpg (on the server) and spok_bad_file.jpg (on my desktop) have same dimension so I think they are equal. If repeat... If I directly link the moodledata/1/spok.jpg file I can see him.
What happen?
PS: I'm using Linux (Fedora Core 7), Apache 2.
dimension = File Size. ))))
I've tried to put the spok_bad_file.jpg "image" on the server but I can't see him directly with url.
So you have reason. The file.php does not give me the file correctly! But... Why?
My file.php and config.php files don't have empty lines at the beginning.
file.php:
<?php // $Id: file.php,v 1.44.2.1 2007/04/02 16:12:26 skodak Exp $
// This script fetches files from the dataroot directory
// Syntax: file.php/courseid/dir/dir/dir/filename.ext
// file.php/courseid/dir/dir/dir/filename.ext?forcedownload=1
(download instead of inline)
// file.php/courseid/dir (returns index.html from dir)
// Workaround: file.php?file=/courseid/dir/dir/dir/filename.ext
// Test: file.php/testslasharguments
//TODO: Blog attachments do not have access control implemented - anybody
can read them!
// It might be better to move the code to separate file because the a
ccess
// control is quite complex - see bolg/index.php
require_once('config.php');
require_once('lib/filelib.php');
if (empty($CFG->filelifetime)) {
$lifetime = 86400; // Seconds for files to remain in caches
} else {
....
....
....
config.php:
<?php /// Moodle Configuration File
unset($CFG);
$CFG->dbtype = 'mysql';
$CFG->dbhost = 'localhost';
$CFG->dbname = 'moodle';
$CFG->dbuser = 'muser';
$CFG->dbpass = 'mpass';
$CFG->dbpersist = false;
$CFG->prefix = '';
$CFG->wwwroot = 'http://10.0.23.70/moodle';
$CFG->dirroot = '/var/www/html/moodle';
....
....
Thank you very much for support. I hope finally we can solve this problem.
see you soon... bye!
Ps. I can't give you an ssh access.
The problem's almost solved: we know the reason and that's ~98% of the whole task
I hope you have reason this time too.
We, humans, always look for a hard way to do simple things. ;)
Absolutely! I'm sorry... I'm not the boss...
Check this file (lib/filelib.php) also for empty newlines at the beginning of the file.
I'm away at the moment. I will check as soon as possible (tomorrow )...
Thank you again!
Ok... i'm back!
... this is the top of my lib/filelib.php:
<?php //$Id: filelib.php,v 1.39.2.6 2007/08/23 06:42:24 moodler Exp $
require_once($CFG->libdir.'/libcurlemu/libcurlemu.inc.php'); // might be moved to setup.php later
define('BYTESERVING_BOUNDARY', 's1k2o3d4a5k6s7'); //unique string constant
I've checked libcurlemu/libcurlemu.inc.php also... no empty lines at the beginning.
Thank you again Michael... but I can't...
If you are shure I have a file with empty line I will find it.
Are you shure there are no other ways? Couldn't be a gd problem?
YEEEEEEEEEEEEAAAAAAAAAAAAHHHHHHHHHHH!!!!!!
I've found it!!! The empty line was in the end of config.php file!!!!!!
NOW I CAN SEE IMAGES!!!!!!
THANK YOU MICHAEL!!!!!!!!! YOU ARE MY JEDI MASTER!!!!!!
Now I've to understand what to do with my imported course with blank images... I hope to fix them re-restoring backups files!
THANK YOU!!!
OK, now it's all rights except for user profiles images.
I can see them in user profile page but I can't see the small version in others pages like forums etc...
mmm... interesting...
That's happen only with administrator profile image.
mmm... I think this time is a bit different because I can see all user's images except small administrator's image (the big is ok in the profile page).
Anyway... I can't download small administrator's image because there isn't (blank), so I haven't the option to download it.
Is that:
http://10.0.23.70/moodle/user/view.php?id=2&course=1 .... userpicture = http://10.0.23.70/moodle/user/pix.php?file=/2/f2.jpg
If I go to http://10.0.23.70/moodle/user/pix.php?file=/2/f2.jpg I can't see the image but If I go directly to http://10.0.23.70/moodledata/users/2/f2.jpg I see the image.
This is a link to user's image with no problem: http://10.0.23.70/moodle/user/pix.php?file=/12/f2.jpg
So it seems to be the same...
Is it correct I have id=2 for administrator?
Ok now it's all right!
Probabily it was only a cache problem...
Thank you again Michael!
Bye