For local development on Sina Weibo, the callback address is the same, but it is always error: redirect_uri_mismatch

Source: Internet
Author: User
Sent $ redirectURLapi. weibo. comoauth2authorize? Client_id1_4893821 & amp; redirect_urixxxx.labclosewin % 3 Fsnsapi % 3 Dsina % 26 backUrl % 3D & amp; response_typecode are all local I tested other...

$ Redirect URL sent
Https://api.weibo.com/oauth2/authorize? Client_id = 2644893821 & redirect_uri = http://xxxx.lab/closewin%3Fsnsapi%3Dsina%26backUrl%3D&response_type=code

Both are local

I tested another development environment
Local
Http: // localhost: 1002/sina/callback. php

Authorization successful

Combined with debugging
. '& BackUrl ='. $ _ GET ['backurl']That's why.

This is the reason for local debugging. This problem should not occur during online debugging.

Reply content:

$ Redirect URL sent
Https://api.weibo.com/oauth2/authorize? Client_id = 2644893821 & redirect_uri = http://xxxx.lab/closewin%3Fsnsapi%3Dsina%26backUrl%3D&response_type=code

Both are local

I tested another development environment
Local
Http: // localhost: 1002/sina/callback. php

Authorization successful

Combined with debugging
. '& BackUrl ='. $ _ GET ['backurl']That's why.

This is the reason for local debugging. This problem should not occur during online debugging.

To be in the same domain
If your callback domain name is a.sina.com

Then your url should be xx.sina.com/xxx/aaa? Xxx

Is your callback domain name configured?

The callback address does not seem to contain parameters. There is a solution reference: http://www.xtwind.com/yar-wordpress-twitter-wall-plug-in.html

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.