Home  >  Article  >  WeChat Applet  >  Detailed explanation of two ways to jump to the page in WeChat Mini Program

Detailed explanation of two ways to jump to the page in WeChat Mini Program

高洛峰
高洛峰Original
2017-02-15 11:52:062522browse

WeChat mini program jump page

The mini program page has 2 types of jumps, which can be in the wxml page or js:

1, in In wxml page:

 <navigator url="../index/index">跳转到新页面</navigator>
 <navigator url="../index/index" open-type="redirect">在当前页打开</navigator>
 <navigator url="../index/index" open-type="switchTab">切换到首页Tab</navigator>

2, in js page:

微信小程序 跳转页面的两种方法详解

[Note]Pay attention to the two keywords "page within the application" and "tabBar page" here. The tab page registered in the tabBar in the app.json file is the "tabBar page", and the page not registered in the tabBar is the "page within the application". As shown below: the home page is the "page within the application", and the index and logs pages are the "tabBar page".

微信小程序 跳转页面的两种方法详解

Thank you for reading, I hope it can help you, thank you for your support of this site!

For more WeChat mini programs, please pay attention to the PHP Chinese website for related articles about the two methods of jumping to the page!

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