Ememded jQuery code within ASP.NET

Below is a sample code to have ememded jQuery code within ASP.NET page.

 <% if (abc=="4") { %>
           <script>
                    $("#vist<%=x.ToString()%>").css("color","green");
            </script>
  <% } %>

The above code will add custom CSS code to HTML element with id has string like "visit#". 

Comments

Popular posts from this blog

Top JavaScript courses helping you develop SPFx webPart with ReactJS and AngularJS

SharePoint 2013 error - "Application error when access /_vti_bin/client.svc"

Enable the Microsoft Power BI report file type (.pbix) in SharePoint Search