Here is Client Side Code To Call C# funcation using anchor tag
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
<title></title>
<script type="text/javascript">
function checkMe() {
alert("hello");
PageMethods.MyCSharpMethod("cSharp", onComplete);
}
function onComplete(result, response, content) {
alert(result);
}
</script>
</head>
<body>
<form id="form1" runat="server">
<asp:ScriptManager ID="ScriptManager1" runat="server" EnablePageMethods="true">
</asp:ScriptManager>
<div>
<a href="javascript:;" onclick="checkMe();" runat="server">PK</a>
</div>
</form>
</body>
</html>
C# Function
[System.Web.Services.WebMethod]
public static string MyCSharpMethod(string cSharpeParam)
{
return cSharpeParam;
}