title: Why my link is not working on Asp.Net Master Page?
body: <p>I have a given two link on side navbar. but It's not working why?</p>
  
  <p>Here is my code:</p>
  
  <p><strong>Admin.Master</strong></p>
  
  <pre><code>&lt;div class="w3-sidebar w3-bar-block w3-collapse w3-card-2 w3-animate-left" style="width: 200px; padding-top: 50px;" id="mySidebar"&gt;
          &lt;button type="button" class="w3-bar-item w3-button w3-large w3-hide-large" onclick="w3_close()"&gt;Close &amp;times;&lt;/button&gt;
          &lt;a href="CreateUser.aspx" id="linkCreateUser" class="w3-bar-item w3-button"&gt;Create User&lt;/a&gt;
          &lt;a href="AdminSecurity.aspx" id="linkSecurity" class="w3-bar-item w3-button"&gt;Security&lt;/a&gt;
          &lt;%--&lt;a href="#" class="w3-bar-item w3-button"&gt;Link 3&lt;/a&gt;--%&gt;
      &lt;/div&gt;
      &lt;div class="w3-main" style="margin-left: 200px; padding-top: 50px;"&gt;
  
          &lt;div class="w3-container"&gt;
              &lt;asp:ContentPlaceHolder ID="ContentPlaceHolder1" runat="server"&gt;
              &lt;/asp:ContentPlaceHolder&gt;
          &lt;/div&gt;
      &lt;/div&gt;
  </code></pre>
  
  <p><strong>UPDATE</strong></p>
  
  <pre><code>&lt;asp:LinkButton ID="linkCreateUser" runat="server" PostBackUrl="https://www.google.co.in/?gws_rd=ssl" CssClass="w3-bar-item w3-button"&gt;Create User&lt;/asp:LinkButton&gt;
  &lt;asp:HyperLink ID="HyperLink1" runat="server" Text="Create User hyper" NavigateUrl="CreateUser.aspx" CssClass="w3-bar-item w3-button" &gt;&lt;/asp:HyperLink&gt;
  &lt;a href="AdminSecurity.aspx" runat="server" id="linkSecurity" class="w3-bar-item w3-button"&gt;Security&lt;/a&gt;
  </code></pre>
  
  <p>It appears on chrome browser for above code</p>
  
  <p><strong>Chrome browser</strong></p>
  
  <pre><code> &lt;a id="HyperLink1" class="w3-bar-item w3-button" href="CreateUser.aspx"&gt;Create User hyper&lt;/a&gt;
   &lt;a id="linkCreateUser" class="w3-bar-item w3-button active" href='javascript:WebForm_DoPostBackWithOptions(new WebForm_PostBackOptions("ctl00$linkCreateUser", "", false, "", "https://www.google.co.in/?gws_rd=ssl", false, true))'&gt;Create User&lt;/a&gt;
   &lt;a href="AdminSecurity.aspx" id="linkSecurity" class="w3-bar-item w3-button"&gt;Security&lt;/a&gt;
  </code></pre>
  
  <p><strong>Jquery Click event</strong></p>
  
  <pre><code>$('.w3-sidebar a').click(function (e) {
      e.preventDefault();   // it's not working because of this. But how can I set class = active for clicking link?
      $('.w3-sidebar a').removeClass('active');
      $(this).addClass('active');
  })
  </code></pre>