Monday, May 23, 2016

How to put Bootstrap icon in ASP.NET button?

The HTML code is like this:

<a class="quick-btn" href="#">
   <i class="fa fa-plus-square fa-2x"></i>
   <span>New Job</span> 
</a> 


But I would like to use ASP.NET buttons instead of using HTML.
I found this solution, with using ASP.NET LinkButton.


<asp:LinkButton ID="lbtnNewJob" 
        runat="server" 
        CssClass="quick-btn" onclick="lbtnNewJob_Click">New <br />Job
        <span aria-hidden="true" class="fa fa-plus-square fa-2x"></span>
</asp:LinkButton>

Monday, May 16, 2016

Error from mySQL: ERROR 1820 (HY000): You must reset your password using ALTER USER statement before executing this statement

I got this error when I was trying to use the mySQL command line. I can't even show my databases, because I was asked to reset my password.

I got this error earlier when I was connecting to mySQL using Visual Studio, and I did reset my password. I do not know why I got this again when I am using mySQL command line. I just searched for how to reset password, and it works fine again.

This is how to reset password in mySQL:

ALTER USER 'root'@'localhost' IDENTIFIED BY 'MyNewPass';
Reference: MySQL Reference Manual - How to reset root password?