AKB Forums

Go Back   AKB Forums > Technical sections > Languages, Compilers and Interpreters > Web Development
Home Register Blogs FAQ Members List Calendar Downloads Arcade Mark Forums Read

Web Development Java/PHP/Perl/ASP and more

Troubles when posting message? Click here! :: Проблемы с отправлением сообщения? Нажмите сюда!

Reply
 
LinkBack Thread Tools Display Modes
Old Oct 4, 2004, 19:24   #1
Дошкольник
 
Join Date: Aug 2004
Location: Oxford
Posts: 141
Rep Power: 5
Reputation: 10
JSP & Servlets

Ya tolko nedavno nachal rabotat s JSP, i natolknulsa na problemu: kak mozhno na servere poluchit dostup k faylu, uploadnutomu s pomoshyu HTML (input, style="file")?
Ablertus is offline   Reply With Quote Quote selected
Old Oct 4, 2004, 21:00   #2
Магистр
 
svoy's Avatar
 
Join Date: Nov 2003
Location: heart of europe
Posts: 704
Rep Power: 5
Reputation: 10
Send a message via ICQ to svoy Send a message via AIM to svoy Send a message via MSN to svoy Send a message via Yahoo to svoy Send a message via Skype™ to svoy
tak naizust' ne pomynu u menya ebooki bili gdeto esli xochesh' poishu!
__________________

If you stop, you die! Doc Miles, Crank
svoy is offline   Reply With Quote Quote selected
Old Oct 5, 2004, 10:11   #3
Дошкольник
 
Join Date: Aug 2004
Location: Oxford
Posts: 141
Rep Power: 5
Reputation: 10
Da, budu neskazanno blagodaren
Ablertus is offline   Reply With Quote Quote selected
Old Oct 5, 2004, 11:16   #4
Магистр
 
svoy's Avatar
 
Join Date: Nov 2003
Location: heart of europe
Posts: 704
Rep Power: 5
Reputation: 10
Send a message via ICQ to svoy Send a message via AIM to svoy Send a message via MSN to svoy Send a message via Yahoo to svoy Send a message via Skype™ to svoy
Shas net vremeni zakachat'!
no poishi na google knigi s etimi nazvaniyami naydesh' tochno


Title Size ( Kb )
Java Servlet Programming.pdf 4,424.21
More Servlets and JavaServer Pages.pdf 7,973.09
Servlets v2.3 Spec.pdf 1,290.60
Building Java HTTP servlets.pdf 467.15
Building servlets with session tracking.pdf 479.44
Core Servlets and JavaServer Pages.pdf 11,404.60
Advanced JavaServer Pages.pdf 8,672.48
JavaServer Pages, 1Ed.pdf 2,594.01
JavaServer Pages, 2Ed.rar 5,319.33
__________________

If you stop, you die! Doc Miles, Crank
svoy is offline   Reply With Quote Quote selected
Old Oct 6, 2004, 07:30   #5
СволочЪ
 
Вирус's Avatar
 
Join Date: Aug 2002
Location: Yerevan
Posts: 357
Rep Power: 7
Reputation: 10
Send a message via ICQ to Вирус Send a message via MSN to Вирус
Lightbulb SmartUpload

Quote:
Originally Posted by Ablertus
Ya tolko nedavno nachal rabotat s JSP, i natolknulsa na problemu: kak mozhno na servere poluchit dostup k faylu, uploadnutomu s pomoshyu HTML (input, style="file")?
Есть такая хорошая и очень умная библиотечка - SmartUpload называется. Дополнительную информацию и ссылки на архивы можно найти здесь:

http://www.jguru.com/faq/view.jsp?EID=160
Вирус is offline   Reply With Quote Quote selected
Old Nov 8, 2004, 13:20   #6
Магистр
 
svoy's Avatar
 
Join Date: Nov 2003
Location: heart of europe
Posts: 704
Rep Power: 5
Reputation: 10
Send a message via ICQ to svoy Send a message via AIM to svoy Send a message via MSN to svoy Send a message via Yahoo to svoy Send a message via Skype™ to svoy
Does anyone know how to do copy file or files from on directory to another with servlet?

example. if I start sevlet it should copy a blabla.jar file from folder BLA1 to BLA2
And everything on FreeBSD Server with tomcat Apache Tomcat/5.0.24
__________________

If you stop, you die! Doc Miles, Crank
svoy is offline   Reply With Quote Quote selected
Old Nov 11, 2004, 15:38   #7
Дошкольник
 
Join Date: Aug 2004
Location: Oxford
Posts: 141
Rep Power: 5
Reputation: 10
What is the problem? I would do it with java.io classes, or call the UNIX commands (Runtime.getRunTime().exec("mv ....")). Doesn't it work?
Ablertus is offline   Reply With Quote Quote selected
Old Nov 11, 2004, 16:23   #8
Магистр
 
svoy's Avatar
 
Join Date: Nov 2003
Location: heart of europe
Posts: 704
Rep Power: 5
Reputation: 10
Send a message via ICQ to svoy Send a message via AIM to svoy Send a message via MSN to svoy Send a message via Yahoo to svoy Send a message via Skype™ to svoy
A mozhno aveli konkret??'

I need to delete folder which was created 30 minutes ago. I thing a threads are the best soolution... IMHO

But notice server is hosted so i have just 100% control to Tomcat Webserver and not Unix machine...Thnax in advance
__________________

If you stop, you die! Doc Miles, Crank
svoy is offline   Reply With Quote Quote selected
Old Nov 13, 2004, 11:45   #9
Дошкольник
 
Join Date: Aug 2004
Location: Oxford
Posts: 141
Rep Power: 5
Reputation: 10
Hey, Svoy. I found out that the UNIX machine is absolutely not necessary, the java.io.File has the methods mkdir, list, delete, corresponding to mkdir, ls, rm of UNIX. I have already used it yesterday in my jsp project under Linux, works perfectly. You can also try the renameTo method for moving files/folders, but I can't guarantee the result. As for measuring time, I guess threads are indeed a good idea, I just warn you, that up to my experience, the output in new threads doesn't work properly.
Ablertus is offline   Reply With Quote Quote selected
Old Nov 13, 2004, 11:52   #10
Магистр
 
svoy's Avatar
 
Join Date: Nov 2003
Location: heart of europe
Posts: 704
Rep Power: 5
Reputation: 10
Send a message via ICQ to svoy Send a message via AIM to svoy Send a message via MSN to svoy Send a message via Yahoo to svoy Send a message via Skype™ to svoy
Danke Ablertus!

Yesterday i asked some collegs at Uni they sad that better to use CHRON JOBS I think it is correct writting, I have to look on internet....

So as far as i understood i have to programm Java class and ask my hoster if they can put it as CHRON JOB!
__________________

If you stop, you die! Doc Miles, Crank
svoy is offline   Reply With Quote Quote selected
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



All times are GMT. The time now is 17:18.


Powered by vBulletin® Version 3.6.8
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
This board was founded on September 29, 2001
Powered by Viper Internet

Affordable Web Hosting | ParevNet

Buy text link