Home  >  Article  >  Backend Development  >  The process of obtaining openid from WeChat web page

The process of obtaining openid from WeChat web page

WBOY
WBOYOriginal
2016-07-06 13:52:071049browse

I would like to ask you, what is the process for you to use WeChat silent authorization to obtain openid? I am currently using the QR code to access page 1, and then use page 1 to determine whether there is an openid in the session. If not, jump to WeChat silently. Get the code on the authorization page, return to page 2, get the openid on page 2 and save it in the session, and then return to the original page 1. Doesn’t this seem too cumbersome? Jumping back and forth, there is another problem, I use The test account is the domain name bound to the test account. When WeChat accesses such a page, it will ask the user, either for authorization or to ask whether to continue accessing. I used the official account and there will be no such problem, so , WeChat seems to sometimes convert styles for unbound domain names. Links and buttons won’t work

Reply content:

I would like to ask you, what is the process for you to use WeChat silent authorization to obtain openid? I am currently using the QR code to access page 1, and then use page 1 to determine whether there is an openid in the session. If not, jump to WeChat silently. Get the code on the authorization page, return to page 2, get the openid on page 2 and save it in the session, and then return to the original page 1. Doesn’t this seem too cumbersome? Jumping back and forth, there is another problem, I use The test account is the domain name bound to the test account. When WeChat accesses such a page, it will ask the user, either for authorization or to ask whether to continue accessing. I used the official account and there will be no such problem, so , WeChat seems to sometimes convert styles for unbound domain names. Links and buttons won’t work

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