djmartins Posted November 4, 2005 Report Share Posted November 4, 2005 Man vajadzetu uploudet failus uz db ka to dabut gatavu? scripta sakums: <form enctype='multipart/form-data' action='upload.php' method='post'> <input type='hidden' name='MAX_FILE_SIZE' value='9999999999'> <input name='userfile' type='file'> <input type='submit' value='Upload'> </form> turpinajums:???? Link to comment Share on other sites More sharing options...
orion Posted November 4, 2005 Report Share Posted November 4, 2005 A kamdēļ uz db? Bij jau topics kaut kur par to, ka tas nav labākais veids, kā glabāt failus. Labāk parastā dirā iemet un db glabā linku uz jamo. Vainu kā tev tur vajag. Link to comment Share on other sites More sharing options...
djmartins Posted November 4, 2005 Author Report Share Posted November 4, 2005 hmm nu labi tad vajadzetu glabat uz dir! Bet kaa tad to var izdarit? Link to comment Share on other sites More sharing options...
[Ya] Posted November 4, 2005 Report Share Posted November 4, 2005 if(isset($_FILES['userfile'])) { move_uploaded_file($_FILES['userfile']['tmp_name'],"/path/to/store/dir/".$_FILES['userfile']['name']); } Link to comment Share on other sites More sharing options...
djmartins Posted November 4, 2005 Author Report Share Posted November 4, 2005 Paldies, bet vel viens jautajums kas jaraksta path/to/store/dir/ vietaa?Piemeru luudzu! Link to comment Share on other sites More sharing options...
hmnc Posted November 4, 2005 Report Share Posted November 4, 2005 /var/www/htdocs/domain.lv/pictures/ Link to comment Share on other sites More sharing options...
[Ya] Posted November 4, 2005 Report Share Posted November 4, 2005 tas ir kur likt to failu ibio.... Link to comment Share on other sites More sharing options...
djmartins Posted November 4, 2005 Author Report Share Posted November 4, 2005 /var/www/htdocs/www.members.lycos.co.uk/djmartins/pictures/ Taa jaizskatas?Ja jaa tad nezvai jo man nenem sita preti cip failu tur nesaglaba! Link to comment Share on other sites More sharing options...
hmnc Posted November 4, 2005 Report Share Posted November 4, 2005 mwahahaah! tu prasīji piemēru - es parādīju kāpēc gan nevarētu būt c:/wwwroot/domain.lv/ ? muehe :D Link to comment Share on other sites More sharing options...
djmartins Posted November 4, 2005 Author Report Share Posted November 4, 2005 Neko nerubiju! Kaa man butu jaizskatas ja mana lapa atrodas seit www.members.lycos.co.uk/djmartins ?? un mape kura veletos turet bildes saucas images tad kaads izskatisies sis cels kur sie faili glabasies? Link to comment Share on other sites More sharing options...
[Ya] Posted November 4, 2005 Report Share Posted November 4, 2005 direktorijas permiicijaam jaabuut world writable Link to comment Share on other sites More sharing options...
djmartins Posted November 4, 2005 Author Report Share Posted November 4, 2005 ir jau bet tikunta nekas nenotiek! Link to comment Share on other sites More sharing options...
hmnc Posted November 4, 2005 Report Share Posted November 4, 2005 jopcik! tu zini kas vispār ir direktorija/folderis/mape?! es tev piemērā (!!!!!) minu domain.lv/pictures/ bet tu viņu izmanto (!!!!) un sūdzies, ka neiet, jo bildes tev stāv iekš /images/ domā tak ar galvu! Link to comment Share on other sites More sharing options...
djmartins Posted November 4, 2005 Author Report Share Posted November 4, 2005 folderis un mape nav viens un tas pats? Link to comment Share on other sites More sharing options...
hmnc Posted November 4, 2005 Report Share Posted November 4, 2005 :D:D:D un kā tev liekas?!?!? Link to comment Share on other sites More sharing options...
Recommended Posts