The first connection modifies the URL, making it impossible to get the hash

Good day! I faced this problem. My sitelink contains a hash collected by the program. When I first visit the site, the hash is removed, making it difficult to give feedback to the app.

As a result, the address is changed and the hash that needed to be processed is removed. I have already read about the suffix “?i=1” and understand why it is needed. On the second attempt to contact the address, everything works as it should, but it is inconvenient to use what needs to be reopened in the application.

And so the question is, is it possible to somehow get a hash, or will it be easier to change the hosting? I understand that this is a feature of this hosting, and no amount of paid services or a “Premium” subscription is likely to solve this problem.

I don’t think so. The security system wasn’t very well implemented.

You can try to exchanging data with the same method instead (GET), that will remain unaffected. POST also works.

6 Likes

Unfortunately, I do not have access to the application to change anything there. I only have API documentation and a script that processes this data. As I understood here, only the change of hosting, since I no longer see the possibilities of how to do it.

We discussed this in the past. The issue isn’t that the security system is “poorly implemented”, it’s that doing the redirect you want is technically impossible.

The security system recontructs the redirect URL based on the URL that’s requested from the server. But a URL hash is never sent to the server, it’s only used for browser rendering, so there is no way to include that in the redirect URL.

Maybe it’s possible to work around this with .htaccess rules: have it redirect a URL like /test?hash=abcd&i=1 to /test#hash:abcd. But I will admit that it’s not nice to need a hack like that.

8 Likes

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.