I am currently working on a project where we are able to share via twitter or facebook.
When I am working with twitter share, I found out twitter intent is the best way. But I found a problem when I try to share via twitter using mobile device.
Here is my sample url:
https://twitter.com/intent/tweet?text=Congrats
if user already login, nothing is wrong, but when the user is not login twitter will show login form, and if the user misstype either the username or the password, twitter will redirect it to another page.
Here is the problem, after twitter redirect to another page, the url change into
https://mobile.twitter.com/login/error?username_or_email=sample%40mail.com&redirect_after_login=%2Fintent%2Ftweet%3Ftext%3DCongrats…
when user finally login with the right username and password, twitter will redirect to
https://mobile.twitter.com/intent/tweet?text=Congrats
which is doesn’t exist
What can I do? Much appreciate.