Username is easy: store it in all lower case (in a second field if necessary) and just compare it.
But the password is more complex, because what you are doing is wrong, and could be very expensive for you. Never store passwords in clear text - it is a major security risk. There is some information on how to do it here: Password Storage: How to do it.
] - ignore the code, it's C# based - but the text is still relevant. PHP provides easy to use password hashing functions: Hashing Passwords with the PHP 5.5 Password Hashing API
] and you really should use them.
And remember: if this is web based and you have any European Union users then GDPR applies and that means you need to handle passwords as sensitive data and store them in a safe and secure manner. Text is neither of those and the fines can be .... um ... outstanding. In December 2018 a German company received a relatively low fine of €20,000 for just that.