File uploading is a very common task in web applications and it is frequently necessary to upload a file from client to server. In HTML forms the input type “file” allows the visitor browse the local file system to select the file. When the file is selected it is sent to server as a part of a POST request. During this there are two mandatory restrictions applied to the form with input type file: it must contains attribute enctype set to value multipart/form-data and its method should be POST. Thus, entire request in sent to server in encoded form. JSP container does not parse the content of requests with type multipart. That is why JSP or servlet processing incoming file data has to use own means to handle request and extract a file from there.

We will use Apache commons FileUpload to handle the file on server.
Once it is downloaded, we should copy the jar files under WEB-INF/lib of our application. If we put a library into lib directory newly, we should be aware of the fact that we need to restart Tomcat. >> Continue Reading

Development, JSP & Servlets - Posted by admin on April 18, 2010

No Comments

Last week my collegue Erol worked on the website and organization of first “Barcamp in Antalya”. The website was developed very fast and we already have 34 members. At the time of organization we aim to have 200+ members and participants.

To join us or just to have a visit  Barcamp Antalya

To have an idea about  Barcamp:

What is BarCamp? from Gregg Pollack on Vimeo.

Social - Posted by admin on March 28, 2010

No Comments

On 13th February, during my regular surfing in net, I came across with an event announcement for a webinar at EventBrite. The name of the online course was “Developing Android Applications with Java”, a topic which I am very interested in nowadays. I registered myself to the course same day, it was free, organized by CreativeTechs and O’Reilly Media and held by Tony Hillerson, a mobile developer at EffectiveUI.

The sessions were on Tuesdays and the quality of webinar, content and communication was perfect. A simple task manager application for Android was written in 5 weeks period, including location aware functionalities, Googles Map API, database usage (SqLite) etc. It was very useful for me and also for other Android development beginners, because the basic concepts and fundamentals were explained briefly.

On Mar 16, we had the last session with topic “Tasks Near me”. Next day I got an email with subject “Thank You and a Surprise – Android Phone Giveaway!”.

“We have a surprise for you: we are giving a free Motorola DROID or Nexus One phone to eligible customers as a special thank you for attending this live class and developing with Android.

To see if you qualify for a free phone and to register to receive your phone, please go to oreillynet.com/android/android-giveaway.csp. The deadline for completing the form is 11:59pm PST, March 21, 2010.”

After this great course, O’Reilly prepared a really big surprise to the participants, who had registered the course before 9th March and attended at least 3 sessions.

Now I am waiting for my gift – sponsored by Google. I will be able to test my applications on real device.

For those who are interested:

The video of the course can be purchased for only $99.

Mobile - Posted by admin on March 28, 2010

5 Comments