31 Jul 2012 20:01
Dirty hack for MW-1.19.1 (fix upload images on some hosters)
Фосса <fossa-artem <at> mail.ru>
2012-07-31 18:01:38 GMT
2012-07-31 18:01:38 GMT
Hi, mr. All! When i installed MW-1.19.1 on my hosting i got error messages like 'rename() [function.rename <http://fwiki.whitefossa.ru/index.php/function.rename>]: SAFE MODE Restriction in effect. The script whose uid is 55398 is not allowed to access /var/tmp owned by uid 0 in */home/u48601/whitefossaru/fwiki/includes/upload/UploadStash.php* on line *173*' when trying to upload any image. Safe mode was turned OFF, but this error didn't disappear. Investigations, made by me and Sir. Sheti <sheti <at> furtails.ru> revealed, that my hoster is completely moron. He uses one tempdir /var/tmp for all users of server, and, this directory belongs to root:root. Because it any modification in this directory fails. And, hoster don't allow to change this directory. So, here is dirty workaround by Sheti: 1) Create temp directory in filesystem, accessible by you, than chmod -R 777 it 2) Locate file <mediawiki_dir>/includes/GlobalFunctions.php 3) Find function named 'wfTempDir()' and comment it (this function determines temp directory): //Hoster are idiot, we must make temp yourself /* function wfTempDir() {(Continue reading)
RSS Feed