17488 Posts in 4473 Topics by 1978 members
|
Page:
1
|
Go to End | |
| Author | Topic: | 1157 Views |
-
Moved to different server, problems with media section. Uploading images etc

19 September 2007 at 11:05pm
If someone would be so kind to help me out with this problem that would be great.
I recently moved my SS site from one server to another, i took a SQL dump of the database and set it up fine, and ftp'd an exact copy of the files to the new server. After a little tweaking with the .htaccess file, it all worked fine, other than the 'Files and Assets' section, and also any page that contained an image from that section. note: the assets folder is chmod'd to 775
I got a red box with FATAL ERROR: and whatever function that related to what i just did 'eg. ulpoad image or create folder'
So, i thought maybe an update to the latest build would cure my woes, but no, same problem still exists.
the error is along these lines (sorry for the large paste)
FATAL ERROR: move_uploaded_file() [function.move-uploaded-file]: open_basedir restriction in effect. File(/tmp/php_upload/phpss2q2o) is not within the allowed path(s)
At line 155 in /home/el/ele/electiontracker.com.au/public/www/gmaps/cms/code/AssetAdmin.phpmove_uploaded_file(/tmp/php_upload/phpss2q2o,/home/el/ele/electiontracker.com.au/public/www/gmaps/silverstripe-cache/_media014.jpg)
line 155 of AssetAdmin.phpAssetAdmin->doUpload(Array,Form)
line 165 of Controller.phpController->run(Array)
line 53 of Director.phpDirector::direct(/admin/assets/index/19)
line 101 of main.php
Context
Debug (Debug::showError() in line 147 of Debug.php)* data =
o url =/gmaps/admin/assets/index/19
o executeForm =
UploadForm
o ID =
19
o action_doUpload =
1
o MAX_FILE_SIZE =
31457280
o action_upload =
Upload Files Listed Below
o Files =
+ name =
# 1 =# 0 =
_media014.jpg
+ type =
# 1 =# 0 =
image/jpeg
+ tmp_name =
# 1 =# 0 =
/tmp/php_upload/phpss2q2o
+ error =
# 1 =4
# 0 =
0
+ size =
# 1 =0
# 0 =
49174
* form =
Form
o HiddenFieldHiddenField (ID: : ) = 19
o HiddenFieldHiddenField (action_doUpload: : ) = 1
o FileFieldFileField (Files[0]: Choose file : ) =
o LiteralFieldLiteralField (UploadButton: UploadButton : ) =
o LiteralFieldLiteralField (MultifileCode: MultifileCode : ) =
* files =
o 1 =0
o 0 =
49174
* param =
size
* value =
49174
* key =
0
* processedFiles =
o 1 =
+ name =+ type =
+ tmp_name =
+ error =
4
+ size =
0
o 0 =
+ name =_media014.jpg
+ type =
image/jpeg
+ tmp_name =
/tmp/php_upload/phpss2q2o
+ error =
0
+ size =
49174
* folder =
Database record: Folder
o ID :19
o ClassName :
Folder
o Created :
2007-09-19 19:41:28
o LastEdited :
2007-09-19 19:41:28
o Name :
NewFolder
o Title :
NewFolder
o Filename :
assets/Uploads/NewFolder/
o Content :
o Sort :
0
o ParentID :
1
o OwnerID :
0
o RecordClassName :
Folder
* newFiles =
* fileSizeWarnings =* uploadErrors =
* file =
o name =_media014.jpg
o type =
image/jpeg
o tmp_name =
/tmp/php_upload/phpss2q2o
o error =
0
o size =
49174
* newtmp =
/home/el/ele/electiontracker.com.au/public/www/gmaps/silverstripe-cache/_media014.jpg
Please help, the client wants to go live soon and ive tried everything i can.
also, ive checked with the hosting company and they say that mod_rewrite is enabled and AllowOverride is set to all
thanks in advance
-
Re: Moved to different server, problems with media section. Uploading images etc

21 September 2007 at 9:42am
The problem is the openbase dir restriction in the servers php.ini doesn't include /tmp. If you have access to php.ini, you should add it in. Otherwise, if you download SilverStripe 2.1.0-rc1 and create a folder named silverstripe-cache on the same level as sapphire, cms, jsparty then it should work.
| 1157 Views | ||
|
Page:
1
|
Go to Top |


