title: GridView with Images and text not showing as i want to
body: <p>I have a gridview on my app that is being populated by my webpage, the thing is that i have the Image and the name of the image but the text it's being showed at a side and not below of the image, how can i achieve that?</p>
  
  <p>Thanks.</p>
  
  <p>This is my code:</p>
  
  <pre><code>public class ListViewAdapter2 extends BaseAdapter {
  
      // Declare Variables
      Context context;
      LayoutInflater inflater;
      ArrayList&lt;HashMap&lt;String, String&gt;&gt; data;
      ImageLoader imageLoader;
      HashMap&lt;String, String&gt; resultp = new HashMap&lt;String, String&gt;();
      String coment;
      public String img;
      public int imga;
      public ListViewAdapter2(Context context,
              ArrayList&lt;HashMap&lt;String, String&gt;&gt; arraylist) {
          this.context = context;
          data = arraylist;
          imageLoader = new ImageLoader(context);
      }
  
      @Override
      public int getCount() {
          return data.size();
      }
  
      @Override
      public Object getItem(int position) {
          return null;
      }
  
      @Override
      public long getItemId(int position) {
          return 0;
      }
  
      public void addItems(ArrayList&lt;HashMap&lt;String, String&gt;&gt; arraylist) {
          if(data != null) {
               data.addAll(arraylist);  
          } else {
               data = arraylist;
          }
      }
  
      public View getView(final int position, View convertView, ViewGroup parent) {
          // Declare Variables
  
          final String enlace;
  
          View itemView = convertView;
          RecordHolder holder = null;
  
          LayoutInflater inflater = ((Activity) context).getLayoutInflater();
  
          itemView = inflater.inflate(R.layout.listview_item2, parent, false);
          // Get the position
          holder = new RecordHolder();
          resultp = data.get(position);
  
          // Locate the TextViews in listview_item.xml
          // Locate the ImageView in listview_item.xml
          holder.imagen = (ImageView) itemView.findViewById(R.id.snapshotcam);
          holder.nombrecam = (TextView) itemView.findViewById(R.id.nombrecam);
          itemView.setTag(holder);
          // Capture position and set results to the TextViews
          // Capture position and set results to the ImageView
          // Passes flag images URL into ImageLoader.class
          imageLoader.DisplayImage(resultp.get(MainActivity.IMAGEN), holder.imagen);
          holder.nombrecam.setText(resultp.get(MainActivity.NOMBRECAM));
          enlace = (resultp.get(MainActivity.ENLACE));
          holder.imagen.setOnClickListener(new OnClickListener() {
  
                  @Override
                  public void onClick(View arg0) {
  
                      Intent i=new Intent(context,VideoPlayer.class);
                      i.putExtra("enlace", enlace);
                      context.startActivity(i);
  
                  }
              });
  
          return itemView;
      }
  
      static class RecordHolder { 
          ImageView imagen;
          TextView nombrecam;
          }
  }
  
  &lt;?xml version="1.0" encoding="utf-8"?&gt;
  &lt;RelativeLayout
      xmlns:android="http://schemas.android.com/apk/res/android"
      xmlns:tools="http://schemas.android.com/tools"
      android:layout_width="match_parent"
      android:layout_height="match_parent"
      android:paddingBottom="@dimen/activity_vertical_margin"
      android:paddingLeft="@dimen/activity_horizontal_margin"
      android:paddingRight="@dimen/activity_horizontal_margin"
      android:paddingTop="@dimen/activity_vertical_margin"
      tools:context=".MainActivity"&gt;
  &lt;GridView 
      android:id="@+id/gridcams"
     android:layout_width="fill_parent"
     android:layout_height="wrap_content"
     android:layout_margin="4dp"
     android:columnWidth="150dp"
     android:gravity="center"
     android:numColumns="auto_fit"
     android:stretchMode="columnWidth" &gt;
  &lt;/GridView&gt;
  &lt;/RelativeLayout&gt;
  
  &lt;?xml version="1.0" encoding="utf-8"?&gt;
  &lt;LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
      android:layout_width="wrap_content"
      android:layout_height="wrap_content"
      android:padding="5dp" &gt;
  
      &lt;ImageView
          android:id="@+id/snapshotcam"
          android:layout_width="100dp"
          android:layout_height="100dp"
          android:layout_marginRight="5dp"&gt;
      &lt;/ImageView&gt;
  
      &lt;TextView
          android:id="@+id/nombrecam"
          android:layout_width="wrap_content"
          android:layout_height="wrap_content"
          android:layout_marginTop="5dp"
          android:textSize="9sp" &gt;
      &lt;/TextView&gt;
  &lt;/LinearLayout&gt;
  </code></pre>