【发布时间】:2014-10-16 00:08:33
【问题描述】:
我对 magento 非常陌生,使用 magento 创建了一个站点。所有功能在 localhost 中运行良好。当我将该代码上传到在线(服务器)时,我遇到了一个问题。除了所有功能都运行良好。
While am uploading an image i got the issue "Unable to create directory".
Images are uploading to tmp path but not moving to target path. Because when am press the button 'upload files', I can able to see the upload percentages. That is why am thing the files are not moving due to dynamic directory creation fails.
I have tried lot but i can't able to make it as work.
I had tried the following solution,
1. Changed the media file permission to 777.
2. Created one tmp directory under /var/ directory and assigned manually in as tmp directory by change the line 91 of lib/Zend/Cache/Backend/File.php ('cache_dir' => null to 'cache_dir' => 'var/tmp').
3. Changed the php.ini file under the magento root directory.
Newly added lines are,
magic_quotes_gpc = off
short_open_tag = on
extension=pdo.so
extension=pdo_mysql.so
4. Checked whether GD library installed or not. It was installed.
5. Changed scope attribute in Magento admin panel -> Catalog -> Attributes -> Manage attributes. After this you should find image, small_image & thumbnail attributes. Then am changed all these attributes scope to Global.
提前非常感谢。请分享你的想法。也欢迎发表您的评论。
【问题讨论】:
标签: admin product magento-1.8 image-upload