Question: All,
I have the following jQuery code:

```
jQuery.ajax({
        type: "POST",
        url: "http://localhost/oml/save_song.php",
        dataType: "json",
        data: "song_id=" + song_id + "&love_like_hate=love",
        async: false,
        success:function(response){
        alert(response.responseText1);
})

```

Then I have on the save\_song.php file this code:

```
$song_id = $_POST['song_id'];
$love_like_hate = $_POST['love_like_hate'];

echo json_encode(array('responseText1' => 'It is: '.$love_like_hate));

```

For some reason if I run this code outside of wordpress it works perfectly fine, however when I'm executing this code from within wordpress it only posts the song\_id and not the love\_like\_hate. 

**EDIT:** When I mean within Wordpress I mean that I installed the Exec-PHP plugin and am writing the PHP and jQuery directly in one of my pages that I created. If I just run it on a normal php file without being a wordpress page it works fine.

Answer: 
You should look at [this](http://source.android.com/source/code-style.html)  on How to code in android.

And you can use inner class or make a seprate class according to your need. For example when all data is being loaded from web in json format i always use a seprate class with a static method which will return the `jsonObject` and then i can call this method anywhere in my app and extract data from it.
Also i use single inner class of `asyncTask` perfoming different task in my activity like seraching and loading data in `listview`, loading data on user prefrences change.and so on.
In custom adapter i always prefer different class for them. It'll really make easy to work with them. 
Hope it will help.
I've asked this before, and this is the way I do it. 

If I'm going to use the adapter many times, I place all of my adapters into a package called "com.myapp.adapters" As for the AsyncTask, I always use asynctasks as part of activities.

If you only have a short adapter that does a little bit of work in an activity, there's no need to create a separate class file for it. Just stick it into the activity.