<a href="#">Text</a>
The above is commonly used such that Text gains the appearance of a link while it does not actually link anywhere. However, this is the wrong method because # actually links to the top of the web page. The correct way to suppress such link is with href="javascript:;".
P.S. Of course, there might be cases where the intention _is_ to go to the top of the page. This needs to be examined case-by-case.
Taking this one!
@wkurniawan07 , using href="javascript:;" might cause redirection to page not found on clicking it. Please have a look at #7206
@VamsiSangam not sure but I guess you removed href="$javascript:;" and @wkurniawan07 is asking to add href="javascript:;". Maybe in your case, this $ might be causing problem. Code link
@VamsiSangam: @amarlearning was right, it was the $ prepended to it that caused trouble. href="javascript:;" alone does not have any drawback like that.
Most helpful comment
@VamsiSangam: @amarlearning was right, it was the
$prepended to it that caused trouble.href="javascript:;"alone does not have any drawback like that.