Warning: file_get_contents(/data/phpspider/zhask/data//catemap/3/html/80.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Android 嵌套ScrollView中带有锚定的Webview_Android_Html_Webview_Android Nestedscrollview - Fatal编程技术网

Android 嵌套ScrollView中带有锚定的Webview

Android 嵌套ScrollView中带有锚定的Webview,android,html,webview,android-nestedscrollview,Android,Html,Webview,Android Nestedscrollview,我有一个嵌套的ScrollView,里面有一个WebView。WebView包含一个带有锚定的HTML文件,这些锚定链接到同一个文件但位置不同(想象一下“菜单”和“内容”容器。当您单击菜单项时,“内容”中的相应部分应显示在屏幕上) 问题是这些锚定无法按预期工作。您是否找到了解决方案?没有,抱歉。但当时是3岁。以前。你有没有找到解决办法?没有,对不起。但当时是3岁。以前 <android.support.v4.widget.NestedScrollView xmlns:android="ht

我有一个嵌套的ScrollView,里面有一个WebView。WebView包含一个带有锚定的HTML文件,这些锚定链接到同一个文件但位置不同(想象一下“菜单”和“内容”容器。当您单击菜单项时,“内容”中的相应部分应显示在屏幕上)


问题是这些锚定无法按预期工作。

您是否找到了解决方案?没有,抱歉。但当时是3岁。以前。你有没有找到解决办法?没有,对不起。但当时是3岁。以前
<android.support.v4.widget.NestedScrollView xmlns:android="http://schemas.android.com/apk/res/android"
    xmlns:app="http://schemas.android.com/apk/res-auto"
    xmlns:tools="http://schemas.android.com/tools"
    android:layout_width="match_parent"
    android:id="@+id/svNested"
    android:layout_height="match_parent"
    tools:showIn="@layout/activity_single"
    android:background="@color/colorPrimary">

        <WebView
            android:id="@+id/webView"
            android:layout_width="match_parent"
            android:layout_height="wrap_content"/>

</android.support.v4.widget.NestedScrollView>
webView?.loadDataWithBaseURL(null, htmlContent, "text/html", "UTF-8", null)