View Issue Details
|ID||Project||Category||View Status||Date Submitted||Last Update|
|0003345||OXID eShop (all versions)||1.01. Products (product, categories, manufacturer, promotions etc.)||public||2011-11-02 10:12||2012-12-07 14:13|
|Target Version||Fixed in Version||4.6.0_beta3|
|Summary||0003345: Pictures aren't deleted|
|Description||Whenever I delete assigned picture to category (could be picture , icon, or promo), it isn't actually physically deleted , though it makes an attempt,|
see oxutils.php overwritePic().
Something wrong is with - $sImgDir = $sAbsDynImageDir . $sPicDir;
|Steps To Reproduce||Go to Administer Products -> Categories -> Main;|
Upload icon picture.
Delete it by pressing X.
Upload same picture again.
It will get extra suffix - (1)..
Yes, indeed there are many more places where it happens that pictures are NOT physically deleted. I will start a forum thread about this and/or will report further bugs.
For the category images one solution may be to fix the mentioned $sImgDir assignment like this:
$sImgDir = $sAbsDynImageDir . oxUtilsFile::getInstance()->getImageDirByType( $sPicType );
$sImgDir = $this->getConfig()->getPictureDir(false) . oxUtilsFile::getInstance()->getImageDirByType( $sPicType );
and after that both parameters $sAbsDynImageDir and $sPicDir are obsolet and could be deleted at all. That would simplify the usage of the function overwritePic in class oxutilspic.php. This issue also belongs to wrapping pictures and promo action banners!