Strict Standards: Non-static method utf_normalizer::nfc() should not be called statically in /www/htdocs/w006661d/anddev/includes/utf/utf_tools.php on line 1781
[phpBB Debug] PHP Notice: in file /bbc_download.php on line 73: Cannot modify header information - headers already sent by (output started at /includes/utf/utf_tools.php:1781)
[phpBB Debug] PHP Notice: in file /bbc_download.php on line 74: Cannot modify header information - headers already sent by (output started at /includes/utf/utf_tools.php:1781)
[phpBB Debug] PHP Notice: in file /bbc_download.php on line 75: Cannot modify header information - headers already sent by (output started at /includes/utf/utf_tools.php:1781)
[phpBB Debug] PHP Notice: in file /bbc_download.php on line 76: Cannot modify header information - headers already sent by (output started at /includes/utf/utf_tools.php:1781)
[phpBB Debug] PHP Notice: in file /bbc_download.php on line 77: Cannot modify header information - headers already sent by (output started at /includes/utf/utf_tools.php:1781)
[phpBB Debug] PHP Notice: in file /bbc_download.php on line 78: Cannot modify header information - headers already sent by (output started at /includes/utf/utf_tools.php:1781)
package com.geocoder; import java.io.File; import java.util.List; import android.app.Activity; import android.content.Context; import android.content.Intent; import android.graphics.Bitmap; import android.location.Location; import android.location.LocationManager; import android.net.Uri; import android.os.Bundle; import android.os.Environment; import android.provider.MediaStore; import android.util.Log; import android.view.View; import android.view.View.OnClickListener; import android.widget.Button; import android.widget.EditText; import android.widget.Toast; public class ActivityGeocode extends Activity implements OnClickListener{ /** Called when the activity is first created. */ EditText name; EditText address; EditText comment; Bitmap b=null; private static Uri _outputFileUri; private static File _file; @Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.main); name = (EditText)findViewById(R.id.name); address =(EditText)findViewById(R.id.address); comment = (EditText)findViewById(R.id.comment); Button submit = (Button)findViewById(R.id.submit); submit.setOnClickListener(this); Button clear = (Button)findViewById(R.id.clear); clear.setOnClickListener(this); Button photo = (Button)findViewById(R.id.photo); photo.setOnClickListener(this); } @Override public void onClick(View v) { switch(v.getId()) { case R.id.submit: Api obj = new Api(); LocationManager lm = (LocationManager) getSystemService(Context.LOCATION_SERVICE); List providers = lm.getProviders(true); /* Loop over the array backwards, and if you get an accurate location, then break out the loop*/ Location l = null; for (int i=providers.size()-1; i>=0; i--) { l = lm.getLastKnownLocation(providers.get(i)); if (l != null) break; } double lat=0; double lon=0; if (l != null) { lat = l.getLatitude(); lon = l.getLongitude(); } String url = getString(R.string.url); if (name.length()!=0 && address.length()!=0) { String n = name.getText().toString().trim(); n=n.replaceAll(" ", "_"); url+="&name="+n; String a = address.getText().toString().trim(); a=a.replaceAll(" ", "_"); url+="&address="+a; url+="&long="+lat; url+="&lat="+lon; String c = comment.getText().toString().trim(); c=c.replaceAll(" ", "_"); url+="&comm="+c; } String data = obj.httpGet(url); Log.i("resp",data); Toast.makeText(getBaseContext(), data, Toast.LENGTH_LONG).show(); HTTPuploader uobj = new HTTPuploader(); Imageupload iobj = new Imageupload(); if(b!=null) { int i = uobj.upload(b); //iobj.doFileUpload(_outputFileUri.toString() , _outputFileUri); if (i==1) { Toast.makeText(getBaseContext(), "image upload successful", Toast.LENGTH_LONG).show(); } else { Toast.makeText(getBaseContext(), "image upload fail", Toast.LENGTH_LONG).show(); } } break; case R.id.clear: name.setText(""); address.setText(""); comment.setText(""); break; case R.id.photo: Intent _intent = new Intent(MediaStore.ACTION_IMAGE_CAPTURE); _file = new File(Environment.getExternalStorageDirectory(),"re.jpg"); _outputFileUri = Uri.fromFile(_file); _intent.putExtra(MediaStore.EXTRA_OUTPUT, _outputFileUri); startActivityForResult(_intent, 0); } } @Override protected void onActivityResult(int requestCode, int resultCode, Intent data) { super.onActivityResult(requestCode, resultCode, data); if (resultCode == RESULT_CANCELED) { Toast.makeText(this, "Activity cancelled", Toast.LENGTH_LONG).show(); return; } if (resultCode == RESULT_OK) { try{ b = MediaStore.Images.Media.getBitmap(getContentResolver(), _outputFileUri); } catch(Exception e){ e.printStackTrace(); } } } }