4577 Posts in 1387 Topics by 1377 members
|
Page:
1
|
Go to End | |
| Author | Topic: | 2173 Views |
-
Problems Uploading Files & Images After Install

7 June 2009 at 6:53pm
Hi guys,
Using version 2.3.1 on an Australian host (Ilisys.com.au) and getting a nasty error when trying to upload an image file through 'Files & Images'. I can browse to the image/file ok but when I press the 'Upload Files Listed Below' I get an error.
I am on a shared hosting service and don't have access to php.ini. I've added a folder called 'silverstripe-cache' following reading other forum posts. I adjusted permissions on my assets directory to 777 to see if that helped.
Anyway the error I am receiving is:
[Warning] move_uploaded_file() [function.move-uploaded-file]: open_basedir restriction in effect. File(/tmp/php_upload/phpdx7OzZ) is not within the allowed path(s): (VIRTUAL_DOCUMENT_ROOT:/usr/local/lib/php:/usr/local/lib/ph:/home/chroot_lib/phplib/:/usr/local/bin/)
POST /admin/assets/UploadFormLine 198 in /home/4-web/46/ad/<domain>.com.au/public/www/cms/code/AssetAdmin.php
Any suggestions or help is muchly appreciated.
-
Re: Problems Uploading Files & Images After Install

12 June 2009 at 5:56am
Hi Anthony,
I think I've just had the same problem and I'm on a host with similar restrictions (MelbourneIT = crap) ...As far as I can see I'm not able to upload files because SilverStripe can't find/access a temp folder somewhere..
It may be possible to set the folder manually in AssetAdmin.php (line 198) but I haven't done anything other than have a quick look (it's 2am and I need some sleep). I'll have a go at fixing it tomorrow... In the meantime if you find solution please share it!
Jack
-
Re: Problems Uploading Files & Images After Install

12 June 2009 at 8:43am
Are you defining your temporary file location? For example, do you have an environment file (_ss_environment.php) that has a line like:
define('TEMP_FOLDER', dirname(getcwd())."/tmp");
-
Re: Problems Uploading Files & Images After Install

16 June 2009 at 1:00am
Awesome work Hamish.
Did exactly as you suggested and added a _ss_environment.php file to the root of my site with the define statement that you gave me. I also created a folder called 'tmp' at this level with the correct permissions!
Really appreciate your help - thanks again. JackAttack if you have this issue follow Hamish's instructions. For more info on _ss_environment.php check out this document http://doc.silverstripe.com/doku.php?id=environment-management
Cheers
Anthony
| 2173 Views | ||
|
Page:
1
|
Go to Top |



