提交 0828dbd3 编写于 作者: Z zhou-liting125

Web documentation rectification

Signed-off-by: Nzhou-liting125 <zhouliting5@huawei.com>
上级 a17adad0
...@@ -355,7 +355,7 @@ databaseAccess(databaseAccess: boolean) ...@@ -355,7 +355,7 @@ databaseAccess(databaseAccess: boolean)
controller:WebController = new WebController(); controller:WebController = new WebController();
build() { build() {
Column() { Column() {
Web({ src:'https://webkit.org/demos/sticky-notes/index.html', controller:this.controller }) Web({ src:'www.example.com', controller:this.controller })
.databaseAccess(true) .databaseAccess(true)
} }
} }
...@@ -1155,7 +1155,7 @@ onHttpAuthRequest(callback: (event?: { handler: HttpAuthHandler, host: string, r ...@@ -1155,7 +1155,7 @@ onHttpAuthRequest(callback: (event?: { handler: HttpAuthHandler, host: string, r
httpAuth:boolean = false; httpAuth:boolean = false;
build() { build() {
Column() { Column() {
Web({ src:'http://httpbin.org/basic-auth/2222/2222', controller:this.controller }) Web({ src:'www.example.com', controller:this.controller })
.onHttpAuthRequest((event) => { .onHttpAuthRequest((event) => {
AlertDialog.show({ AlertDialog.show({
title: 'title', title: 'title',
...@@ -2080,7 +2080,7 @@ loadUrl(options: { url: string | Resource, headers?: Array\<Header\> }) ...@@ -2080,7 +2080,7 @@ loadUrl(options: { url: string | Resource, headers?: Array\<Header\> })
.onClick(() => { .onClick(() => {
this.controller.loadUrl({ url: 'www.example.com' }); this.controller.loadUrl({ url: 'www.example.com' });
}) })
Web({ src: 'https://webkit.org/demos/sticky-notes/index.html', controller: this.controller }) Web({ src: 'www.example.com', controller: this.controller })
} }
} }
} }
...@@ -2516,7 +2516,7 @@ setCookie(url: string, value: string): boolean ...@@ -2516,7 +2516,7 @@ setCookie(url: string, value: string): boolean
Column() { Column() {
Button('setCookie') Button('setCookie')
.onClick(() => { .onClick(() => {
let result = this.controller.getCookieManager().setCookie("http://www.baidu.com", "a=b"); let result = this.controller.getCookieManager().setCookie("www.example.com", "a=b");
console.log("result: " + result); console.log("result: " + result);
}) })
Web({ src: 'www.example.com', controller: this.controller }) Web({ src: 'www.example.com', controller: this.controller })
...@@ -2720,7 +2720,7 @@ static deleteAllData(): void ...@@ -2720,7 +2720,7 @@ static deleteAllData(): void
.onClick(() => { .onClick(() => {
web.WebStorage.deleteAllData(); web.WebStorage.deleteAllData();
}) })
Web({ src: 'https://webkit.org/demos/sticky-notes/index.html', controller: this.controller }) Web({ src: 'www.example.com', controller: this.controller })
.databaseAccess(true) .databaseAccess(true)
} }
} }
...@@ -2752,7 +2752,7 @@ static deleteOrigin(origin : string): void ...@@ -2752,7 +2752,7 @@ static deleteOrigin(origin : string): void
.onClick(() => { .onClick(() => {
web.WebStorage.deleteOrigin(this.origin); web.WebStorage.deleteOrigin(this.origin);
}) })
Web({ src: 'https://webkit.org/demos/sticky-notes/index.html', controller: this.controller }) Web({ src: 'www.example.com', controller: this.controller })
.databaseAccess(true) .databaseAccess(true)
} }
} }
...@@ -2794,7 +2794,7 @@ static getOrigins(callback: AsyncCallback<Array<[WebStorageOrigin]>>) : void ...@@ -2794,7 +2794,7 @@ static getOrigins(callback: AsyncCallback<Array<[WebStorageOrigin]>>) : void
} }
}) })
}) })
Web({ src: 'https://webkit.org/demos/sticky-notes/index.html', controller: this.controller }) Web({ src: 'www.example.com', controller: this.controller })
.databaseAccess(true) .databaseAccess(true)
} }
} }
...@@ -2836,7 +2836,7 @@ static getOrigins() : Promise<Array<[WebStorageOrigin]>> ...@@ -2836,7 +2836,7 @@ static getOrigins() : Promise<Array<[WebStorageOrigin]>>
console.log('error: ' + error); console.log('error: ' + error);
}) })
}) })
Web({ src: 'https://webkit.org/demos/sticky-notes/index.html', controller: this.controller }) Web({ src: 'www.example.com', controller: this.controller })
.databaseAccess(true) .databaseAccess(true)
} }
} }
...@@ -2875,7 +2875,7 @@ static getOriginQuota(origin : string, callback : AsyncCallback<number>) : void ...@@ -2875,7 +2875,7 @@ static getOriginQuota(origin : string, callback : AsyncCallback<number>) : void
console.log('quota: ' + quota); console.log('quota: ' + quota);
}) })
}) })
Web({ src: 'https://webkit.org/demos/sticky-notes/index.html', controller: this.controller }) Web({ src: 'www.example.com', controller: this.controller })
.databaseAccess(true) .databaseAccess(true)
} }
} }
...@@ -2918,7 +2918,7 @@ static getOriginQuota(origin : string) : Promise<number> ...@@ -2918,7 +2918,7 @@ static getOriginQuota(origin : string) : Promise<number>
console.log('error: ' + error); console.log('error: ' + error);
}) })
}) })
Web({ src: 'https://webkit.org/demos/sticky-notes/index.html', controller: this.controller }) Web({ src: 'www.example.com', controller: this.controller })
.databaseAccess(true) .databaseAccess(true)
} }
} }
...@@ -2957,7 +2957,7 @@ static getOriginUsage(origin : string, callback : AsyncCallback<number>) : void ...@@ -2957,7 +2957,7 @@ static getOriginUsage(origin : string, callback : AsyncCallback<number>) : void
consloe.log('usage: ' + usage); consloe.log('usage: ' + usage);
}) })
}) })
Web({ src: 'https://webkit.org/demos/sticky-notes/index.html', controller: this.controller }) Web({ src: 'www.example.com', controller: this.controller })
.databaseAccess(true) .databaseAccess(true)
} }
} }
...@@ -3000,7 +3000,7 @@ static getOriginUsage(origin : string) : Promise<number> ...@@ -3000,7 +3000,7 @@ static getOriginUsage(origin : string) : Promise<number>
console.log('error: ' + error); console.log('error: ' + error);
}) })
}) })
Web({ src: 'https://webkit.org/demos/sticky-notes/index.html', controller: this.controller }) Web({ src: 'www.example.com', controller: this.controller })
.databaseAccess(true) .databaseAccess(true)
} }
} }
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册