I'm trying to work with google maps for android v2. I followed the instructions from:
https://developers.google.com/maps/documentation/android/start
I'm at the bottom (of the above webpage) where it says "Add a Map". When I copy and paste the following code into my main.xml:
<fragment xmlns:android="http://schemas.android.com/apk/res/android"
android:id="@+id/map"
android:layout_width="match_parent"
android:layout_height="match_parent"
class="com.google.android.gms.maps.MapFragment"/>
I am greeted by an error on the Linearlayout tag that says: "The markup in the document following the root element must be well-formed."
Here is main.xml in its entirety:
<?xml version="1.0" encoding="utf-8"?>
<fragment xmlns:android="http://schemas.android.com/apk/res/android"
android:id="@+id/map"
android:layout_width="match_parent"
android:layout_height="match_parent"
class="com.google.android.gms.maps.MapFragment"/>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:orientation="horizontal"
android:padding="30dip">
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center"
android:layout_marginBottom="25dip"
android:text="@string/welcome"
android:textSize="24sp"/>
<EditText
android:id="@+id/editText1"
android:layout_weight="1"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:ems="10"
android:hint="@string/edit_location"/>
<Button
android:id="@+id/find_me_button"
android:layout_weight="0"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:text="@string/button_find_me"/>
</LinearLayout>
WHY is this not well-formed?
edit: I've tried deleting "xmlns:android="http://schemas.android.com/apk/res/android" from LinearLayout but it doesn't make a difference.