to upload video to a php server through android
<p>This is what I am doing to upload a video to a server:</p>

<p><em>email<br/>
gameId<br/>
source<br/>
uploadedfile</em></p>

<p>are the parameters that have to be sent. <code>email</code>, <code>gameId</code> and <code>source</code> are string values, 
whereas <code>uploadedfile</code> is the filebody to be uploaded.</p>

<p>Running this code gives response <code>error0</code>.</p>

<pre><code> HttpClient client = new DefaultHttpClient();  
                 String postURL = GlobalConfig.url+"uploadBlogData.php";
                 HttpPost post = new HttpPost(postURL); 
                 FileBody bin = new FileBody(file);
                 MultipartEntity reqEntity = new MultipartEntity(HttpMultipartMode.BROWSER_COMPATIBLE);  

             reqEntity.addPart("email", new StringBody(GlobalConfig.pref.getString(GlobalConfig.KEY_User_Emailid,""), "text/plain", Charset.forName( "UTF-8")));
             reqEntity.addPart("gameId", new StringBody(GlobalConfig.pref.getString(
                    GlobalConfig.KEY_Game_Created_id,
                    ""), "text/plain", Charset.forName( "UTF-8")));
         reqEntity.addPart("source", new StringBody("phone", "text/plain", Charset.forName("UTF-8"))); 
         reqEntity.addPart("uploadfile", bin);
         post.setEntity(reqEntity);  
         HttpResponse response = client.execute(post);  

         Log.d("resP",GlobalConfig.getStringFromResponse(response));

         HttpEntity resEntity = response.getEntity();  
</code></pre>
