无法读取未定义的属性“主机”

时间:2013-07-24 09:14:57

标签: android iphone uiwebview cordova android-webview

我遇到了在android / iphone中创建webview并用html填充它的问题。

唯一有效的是: 将嵌入代码从外部URL加载到同一个URL。

可能是什么问题?

thnks,

伊丽莎

1 个答案:

答案 0 :(得分:0)

所以最后我的解决方案很简单。

我有这个源代码:

  if ( !this.host ) {
    this.host = defaultUri.host;
    // port ?
    if ( !this.port ) {
        this.port = defaultUri.port;
        }
    }

添加:try&赶上,一切都会奏效!