I have a layout that looks like this,
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
    android:layout_width="match_parent"
    android:layout_height="match_parent"
    android:orientation="vertical">
    <ScrollView
        android:layout_width="match_parent"
        android:layout_height="wrap_content">
        <LinearLayout
            android:layout_width="match_parent"
            android:layout_height="match_parent"
            android:orientation="vertical">
            <include
                android:layout_width="match_parent"
                android:layout_height="wrap_content"
                layout="@layout/layout1" />
            <TextView
                android:layout_width="match_parent"
                android:layout_height="wrap_content"
                android:layout_weight="1"/>
            <Button
                android:layout_width="wrap_content"
                android:layout_height="wrap_content"
                android:text="button"/>
        </LinearLayout>
    </ScrollView>
</LinearLayout>
I want the button to appear at the bottom of the screen which works fine if use it with an activity.When i try to use it with a fragment though (inside a FrameLayout) the button doesn't show at all.Any suggestions?
EDIT
Thanks for your answers but i've already tried all that.Let me clarify something.I have a main layout that contains a Toolbar and a Framelayout.This FrameLayout is used for my 4-5 app's Fragments.One of them has that previous layout i posted.
 
     
     
     
     
    