tencent cloud

All product documents
Tencent Cloud Super App as a Service
Web-View
Last updated: 2024-11-21 18:48:11
Web-View
Last updated: 2024-11-21 18:48:11
When mini-program developers use the web-view component and want to call mini program API capabilities within an H5 page, they need to implement this using JSSDK.
JSSDK is a toolkit for web developers. By using the JSSDK, web developers can use some of the native capabilities (e.g. camera, album, audio, location, etc.) within the corresponding H5 page to provide users with a better web experience.
Since JSSDK is implemented based on the mini program's web-view component container, it can only be used when the link is opened within a mini-program. For domain management of the webpage, please refer to Platform management or Mini program management - Development management.

How to use

Please load the corresponding JSSDK in the web page, refer to the following code:
<script src="path/to/jssdk.js"></script>

<script>
// go to pay Page from click in H5 Page
document.getElementById("payBtn").click = funciton(e){
wx.miniProgram.navigateTo({url: "/pages/pay/pay"});
}
</script>

Online address



Was this page helpful?
You can also Contact Sales or Submit a Ticket for help.
Yes
No

Feedback

Contact Us

Contact our sales team or business advisors to help your business.

Technical Support

Open a ticket if you're looking for further assistance. Our Ticket is 7x24 available.

7x24 Phone Support
Hong Kong, China
+852 800 906 020 (Toll Free)
United States
+1 844 606 0804 (Toll Free)
United Kingdom
+44 808 196 4551 (Toll Free)
Canada
+1 888 605 7930 (Toll Free)
Australia
+61 1300 986 386 (Toll Free)
EdgeOne hotline
+852 300 80699
More local hotlines coming soon