htaccess rewriterule to special url structure doesn’t work

I want to open remote site page in Chrome (mobile), so came up with this idea;

<a href="intent://;scheme=https;;end">CANCEL</a>

Works pretty awesome, when you use it on other browser, for example Samsung browser, it opens it on chrome and passes the id variable.

But why need users to click when it can be done automatically ? So I created this link scheme to check it works on htaccess

Redirect 301 /cancel intent://;scheme=https;;end

Works if used as and it opens remotesite on chrome. However we have a problem, it lacks of passing id. So I have tried to pass id using RewriteRule;

RewriteRule id/(.+)$ intent://$1#Intent;scheme=https;;end [L,R=301]

However, It opens url but not with chrome as expected. Opens in samsung browser as this;$1#Intent;scheme=https;;end

Read more here:

Content Attribution

This content was originally published by user3304007 at Recent Questions - Stack Overflow, and is syndicated here via their RSS feed. You can read the original post over there.

%d bloggers like this: