Connect Laravel App to Android
<p>I built a small laravel application which just has a form and saves data to the database(phpmyadmin). Now I tried to display that data in my android application, I tried to get it through the ip.</p>

<p>Main Activity looks like this:</p>

<pre><code>public class MainActivity extends Activity {

    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_main);

    }

    public void onConnect(View view) {
        new Thread(){
            public void run(){
                HttpClient myClient = new DefaultHttpClient();
                HttpPost post = new HttpPost("http://192.168.145.33:8000/gaIndex");
                try {
                    List&lt;NameValuePair&gt; myArgs = new ArrayList&lt;NameValuePair&gt;();
                    myArgs.add(new BasicNameValuePair("email", "test@hotmail.de"));
                    myArgs.add(new BasicNameValuePair("password", "test"));
                    post.setEntity(new UrlEncodedFormEntity(myArgs));
                    HttpResponse myResponse = myClient.execute(post);
                    BufferedReader br = new BufferedReader( new InputStreamReader(myResponse.getEntity().getContent()));
                    String line = "";
                    while ((line = br.readLine()) != null)
                    {
                        Log.d("mytag", line);

                    }
                }
                catch (IOException e) {
                    e.printStackTrace();
                }
            }
        }.start();

    }
}
</code></pre>

<p>If i start the app and push the button to connect the console give me bunch of html...</p>

<p>I also got this in the console output:</p>

<blockquote>
  <p>TokenMismatchException
  in VerifyCsrfToken.php
  line 53:</p>
</blockquote>

<p>Does anybody know what I am doing wrong.</p>