omega omega - 5 months ago 10x
HTML Question

How to fix UTF8 URL?

I have links in an html file like


And I want when the user clicks on this link in the browser, the link will


Is There any way to use it using
file ?
If not, how we can do it using a javascript file ?

I don't want to make changes in the files, just add .htaccess or javascript file and the problem is solved.


The problem appears to be that your URL does not contain valid UTF-8 data. There is no UTF-8 sequence that begins with the octet 87.

I'm guessing that your URL is missing a d9 or d8 octet. This URL:


is shown as arabic characters in my browser:

Browser address bar

How the URL is displayed will of course depend on the browser's support for arabic characters, and is not something that can be affected by JavaScript or .htaccess.