Thanks for the reply. But i guess here encoding is the problem. I mean liferay is already doing encoding and converting # sign into %23. While i don't need it.
Even then i tried to encode my URL after your reply with java URL encoder but it does not solve my problem rather it generates now www.myurl.com%2523link which was www.myurl.com%23link before my encoding. What i need is simply www.myurl.com#link .
Thank you very much for your reply. I am sorry if i was unable to explain my problem in a good way. I do know about anchor but thats not the question. My Question is very simple and that is that Liferay is converting # into a hex value( %23) into my URL. I don't want this because only with # sign in URL i can go to the specific paragraph. With %23 in URL it doesn't go to the specific paragraph but when i do replace manually %23 with # in address bar of browser, every thing works fine. I hope now you will understand my problem.
I already understood your problem. You didn't understand my suggestion, which was to look for documentation which explains how Liferay supports anchors in URLs. What you tried didn't work, as you can see. Complaining that Liferay didn't handle it the way you wanted is pointless. You have to find out the right way.