Robis Posted December 30, 2005 Report Share Posted December 30, 2005 Uploadojot failu brinijos, ka to neizdodas izdarit ta pasha skripta izveidotaja direktorija: [error] PHP Warning: move_uploaded_file(): SAFE MODE Restriction in effect. The script whose uid is 1101 is not allowed to access /usr/data/html/pictures/galleries/3 owned by uid 80 in /usr/data/html/modules/admin/gallery/gallery.php on line 62 Protams, ka /usr/data/html/modules/admin/gallery/gallery.php gan izveidoja diru /usr/data/html/pictures/galleries/3 un chmodoja uz 0777, bet uploadot failu uz turieni neizdevās. Vai te ir vainīga iespējamā safe mode? Vai to nevar apiet? Link to comment Share on other sites More sharing options...
Robis Posted December 30, 2005 Author Report Share Posted December 30, 2005 To, ka safe mode ir vainīga es noskaidroju un to, ka ar ini_set() nav iespējams mainīt tās vērtību skripta izpildes laikā, arī. Bet vai nevar kaut kā apiet šito, izņemot safe_mode vērtības mainīšanu (kas pieejama adminam) ? Link to comment Share on other sites More sharing options...
Delfins Posted December 30, 2005 Report Share Posted December 30, 2005 (edited) Mjā, nu kas te vēl nav skaidrs... SAFE MODE Restriction in effectunVai te ir vainīga iespējamā safe mode? Esi pārliecināts, ka tur ir 0777 uz direktoriju? nevar būt, ka skripts kas uztaisīja diru (uid:1101), un viņam iesetojās uid:80... vai nu līks kods kaut kur, vai kas.. Risinājums ir - nomainīt uid direktorijai.. vai laist skriptu ar to pašu uid... Edited December 30, 2005 by Delfins Link to comment Share on other sites More sharing options...
Robis Posted December 30, 2005 Author Report Share Posted December 30, 2005 Nu tas pats skripts tak cenšas uploadot to failu tur pie tam vienā izpildes paņēmienā. Sviesc Link to comment Share on other sites More sharing options...
Delfins Posted December 30, 2005 Report Share Posted December 30, 2005 (edited) Tāpēc ka skriptam (php kodam) dēļ safe_mode ir cits uid, a direktoriju izveidoja apacis visdrīzāk... Liekas gūglē dafiga par šo tematu ir... Atcerējos...!!! ;) Risinājums ir - http://lv2.php.net/manual/en/function.move-uploaded-file.php Edited December 30, 2005 by Delfins Link to comment Share on other sites More sharing options...
Robis Posted December 30, 2005 Author Report Share Posted December 30, 2005 Atcerējos...!!! ;) Risinājums ir - http://lv2.php.net/manual/en/function.move-uploaded-file.php Es jau tieši move_uploaded_file() arī izmantoju faila uploadam! Link to comment Share on other sites More sharing options...
Blitz Posted December 30, 2005 Report Share Posted December 30, 2005 However, restrictions are placed only on the destination path as to allow the moving of uploaded files in which filename may conflict with such restrictions Link to comment Share on other sites More sharing options...
Robis Posted December 30, 2005 Author Report Share Posted December 30, 2005 Nu sviesc! Tātad risinājumu bez safe mode atslēgšanas nav? Link to comment Share on other sites More sharing options...
Recommended Posts