Struggling with user login

Hello!

I’m struggling with a php tutorial. This one to be specific: https://webdamn.com/build-helpdesk-system-with-php-mysql/

I created the tables in the DB, I add users, but it won’t let me login with them. I can’t figure out what I’m missing and it’s really starting to frustrate me.

What am I missing? Any ideas?

The link you posted doesn’t contain any login code. They do reference another tutorial for managing users though, which again references yet another tutorial that handles login.

All of the tutorials are garbage, please do not use them for anything that will be published on the internet. They don’t adhere to modern standards (talking 10+ year old standards here) with protecting against sql injection, xss, etc.

I’m a firm believer that security is hard, so it’s one of the last things you should reinvent yourself. There are lots of debate here and elsewhere on using frameworks with purists saying it’s much better to learn all the fundamentals yourself. But if you want a site/app out there and don’t want to spend years learning to code / web security / sysadmin stuff then relying on someone else from time to time seems like a great idea in my mind. Frameworks like Laravel fixes all this for you and is vetted by a lot of people who really know what they are doing. Security is HARD, the only easy thing about it is messing up…

If you want to just make something yourself then there are other tutorials on user login out there. I don’t completely agree with this one either but at least it’s better.

OP, you were informed in the other forum that code is insecure junk vulnerable to XSS Attacks.

Another option would to be to have a social login with Facebook in particular in mind. You have to meet their requirements first and have a test website so the people at Facebook can look (test?) in order to approve your website. However, if you meet their requirements then you pretty can be assured that website is secured.

Sponsor our Newsletter | Privacy Policy | Terms of Service