Fix: Removed warning
This commit is contained in:
parent
65ee384aea
commit
50d39ca248
@ -2431,7 +2431,7 @@ class Product extends CommonObject
|
|||||||
* \brief Deplace fichier recupere sur internet (utilise pour interface avec OSC)
|
* \brief Deplace fichier recupere sur internet (utilise pour interface avec OSC)
|
||||||
* \param sdir Repertoire destination finale
|
* \param sdir Repertoire destination finale
|
||||||
* \param $files url de l'image
|
* \param $files url de l'image
|
||||||
* \author Jean Heimburger juin 2007
|
* \author Jean Heimburger june 2007
|
||||||
*/
|
*/
|
||||||
function add_photo_web($sdir, $file)
|
function add_photo_web($sdir, $file)
|
||||||
{
|
{
|
||||||
@ -2451,13 +2451,14 @@ class Product extends CommonObject
|
|||||||
// \todo A faire
|
// \todo A faire
|
||||||
|
|
||||||
// Cree fichier en taille origine
|
// Cree fichier en taille origine
|
||||||
$content = file_get_contents($file);
|
$content = @file_get_contents(urlencode($file));
|
||||||
|
if( $content)
|
||||||
$nom = basename($file);
|
{
|
||||||
$im = fopen(dol_osencode($dir.$nom),'wb');
|
$nom = basename($file);
|
||||||
fwrite($im, $content);
|
$im = fopen(dol_osencode($dir.$nom),'wb');
|
||||||
fclose($im);
|
fwrite($im, $content);
|
||||||
// }
|
fclose($im);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user