Home  >  Article  >  Web Front-end  >  Summary of WeChat Mini Program Development Experience

Summary of WeChat Mini Program Development Experience

怪我咯
怪我咯Original
2017-06-26 11:54:011171browse

1. The WeChat developer tool reports an error. The WeChat applet needs to support at least the tls1.2 version.

The reason is that the server does not support higher versions of SSL. The solution is:

In the /etc/nginx/conf.d file, change "ssl_protocols TLSv1;" to: "ssl_protocols TLSv1 TLSv1.1 TLSv1.2;", and then restart nginx.

2. The problem that the mini program page cannot be loaded by sliding down

scroll-view needs to fix the height. Fix the height of the scroll-view component from 100% and write a number. That’s it, such as 1000rpx.

3. Page forwarding event

About the page forwarding function, onShareAppMessage: function (res), the on event is the highest level event and must exist alone and cannot be placed in the app , app.js is where program events are placed. Therefore, you need to use this event function on every page to use the forwarding function on every page.

4. The title of each page

The title of the home page can be written in the global app.json: {"window": {"navigationBarTitleText": "Love entrepreneurship and love live streaming" }}, the "window" object is a global object, and other page setting titles need to be written separately in the page.json of each page: {"navigationBarTitleText":"Title of each page"}

5. Use Links pass parameters between pages

  type =type;       wx.navigateTo({ url: '../video/video?type=' +type });1 onLoad(options) {     2 3 }

 

The above is the detailed content of Summary of WeChat Mini Program Development Experience. For more information, please follow other related articles on the PHP Chinese website!

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn