Wednesday, April 4, 2018

Android SMS app ignores a trailing “?” when the URL containing a trailing “?” is clicked

Leave a Comment

I send an SMS saying "Click on https://www.example.com/?"

When I receive this SMS on an Android phone, only the https://www.example.com is clickable. The "?" is visible in the SMS, but is not part of the clickable URL.

Is there some way to escape the ? or do some other workaround so that click on the link goes to https://www.example.com/?

EDIT: Forget Android - even on this page on stackoverflow - the "?" is not part of the clickable link

3 Answers

Answers 1

Can you replace the question mark (?) by %3F

www.example.com/%3F

See:

https://www.w3schools.com/tags/ref_urlencode.asp

Answers 2

This appears to be correct behaviour (as far as I have observed on other systems) - an empty query string (effectively a dangling question mark) is not necessarily part of the URL so appears as punctuation.

As a workaround my suggestion is to ensure you always provide a parameter:

https://www.example.com/?a=a 

Ideally you can find something that makes the link enticing to the user (rather than only confusing):

https://www.example.com/?vip=yes 

Because these are not query parameters you are actually using, they should not affect your page processing

Answers 3

Hi you can send by converting to short url by https://goo.gl/ and you can get same as expected .

If You Enjoyed This, Take 5 Seconds To Share It

0 comments:

Post a Comment