Welcome, Guest
Username: Password: Remember me

TOPIC: delete product picture gives error

delete product picture gives error 1 year 5 months ago #22626

  • peve
  • peve's Avatar
  • OFFLINE
  • Fresh Boarder
  • Posts: 5
  • Karma: 1
When I confirm the deletion of a product picture with "[" and "]" in the file name, Dolibarr 3.3.1 gives messages and does not delete the picture, while there were no messages when uploading or showing it. Pictures with other file names are deleted without messages.

Messages when trying to delete:

Warning: Invalid argument supplied for foreach() in dolibarr/htdocs/core/lib/files.lib.php on line 757
and
Warning: Cannot modify header information - headers already sent by (output started at dolibarr/htdocs/core/lib/files.lib.php:757) in dolibarr/htdocs/main.inc.php on line 825

I think an adjustment in the PHP code has to be made to prevent these errors and to make the deletion possible.
Apart from this, is there a way to delete these pictures?
The administrator has disabled public write access.

Re: delete product picture gives error 1 year 5 months ago #22655

  • eldy
  • eldy's Avatar
  • OFFLINE
  • Administrateur
  • Posts: 1392
  • Thank you received: 6
  • Karma: 150
You can delete manually files. Make a scan of file into dolibarr "documents" directory.

Fix should be included into 3.4
Laurent Destailleur (alias eldy, Dolibarr grade: Yoda).
- Dolibarr in the Cloud: DoliCloud, the OpenSource hosting solution for your Dolibar ERP & CRM.
- Android app for Dolibarr: DoliDroid
- Teclib.com, your Open source solution
Last Edit: 1 year 5 months ago by eldy.
The administrator has disabled public write access.
Time to create page: 0.074 seconds