anonīms Posted January 15, 2009 Report Share Posted January 15, 2009 (edited) Mēģinu sataisīt tā, lai varētu izdzēst bildes no foldera. Warning: unlink() [function.unlink]: open_basedir restriction in effect. File(/images/news/big/1232041406.jpg) is not within the allowed path(s): unlink("/images/news/big/".time().".jpg"); Kur kļūda? Edited January 15, 2009 by anonīms Link to comment Share on other sites More sharing options...
martins256 Posted January 15, 2009 Report Share Posted January 15, 2009 Tavs skripts izpildās uz hostinga vai lokālā kompja? pirmo tekstu izlasīji vispār? Faila ar nosaukumu time().'.jpg'; tiešām ir tas, kas jādzēš? Link to comment Share on other sites More sharing options...
anonīms Posted January 15, 2009 Author Report Share Posted January 15, 2009 Jā bilde /images/news/big/1232041406.jpg ir jādzēš. (Viņa arī eksistē) Skripts izpildās uz hostinga. astrons.com Link to comment Share on other sites More sharing options...
Aleksejs Posted January 15, 2009 Report Share Posted January 15, 2009 http://lv.php.net/manual/en/features.safe-mode.php#40870 Vai tiešām ir tāda mape /images root / katalogā? vai gadījumā nevajadzēja: unlink("./images/news/big/".time().".jpg"); Link to comment Share on other sites More sharing options...
anonīms Posted January 15, 2009 Author Report Share Posted January 15, 2009 (edited) mape kā tāda atrodas www/images/ Viss iet! unlink("images/news/big/".time().".jpg"); Edited January 15, 2009 by anonīms Link to comment Share on other sites More sharing options...
Aleksejs Posted January 15, 2009 Report Share Posted January 15, 2009 Nu, lūk! tas ceļš, ko padod unlink() ir lokālais ceļš diskā. Tas, ka htmlā to norāda <img src="/images..."> nenozīmē, ka lokālajā failu sistēmā šis ceļš arī sākas saknes katalogā. Link to comment Share on other sites More sharing options...
Recommended Posts