HTML does not work properly for url

I am trying to create a url:

Get-it-together-Stavros-Zenonos amplifier ;? -Katerina-Ko ViewMode = 0

Where you can see "amp;" after that url does not generate

As below:

Get-It-Together-Stavros-Zenonos Amplifiers

See my code below which generates the URL

<a class="fb-xfbml-parse-ignore" href="https://twitter.com/intent/tweet?url=<%=HTMLEncode(CMS.DocumentEngine.DocumentContext.CurrentDocument.AbsoluteURL)%>" onClick="return popup(this, 'notes')"> <img src="<%# Eval("twittericon") %>" alt="twitter icon" /> </a> 

Could you help me do this to create a complete URL?

+5
source share
1 answer

The problem is that you are using HTMLEncode for the value in the url. You should use URLEncode .

+2
source

Source: https://habr.com/ru/post/1262078/


All Articles