Podcast #128: We chat with Kent C Dodds about why he loves React and discuss what life was like in the dark days before Git. Listen now.

New answers tagged

1

I am more a man of practice than of advise. Maybe because I feel the responsibility for the advise I give out. Some advises are much simpler to be given than implemented. I need to make sure that my advise won't raise more questions than it does answer - otherwise it will be anything but help. It is simple to say "use prepared statements" but how exactly ...


2

Just a few things to add to mickmackusa's excellent answer... Consider using the <label> HTML tag In things like Username: <input type="text" name="username" maxlength="15"/> When you click on a label, focus is sent to the input associated with it. This helps improve accessibility as well as other benefits - Why use <label>? <...


2

openConnection() is written to die() internally if there is a connection error, there is no need for you to write: if ($conn->connect_error) { die("Connection failed: " . $conn->connect_error); } I do not recommend that you provide the precise mysql error when something goes wrong. It is better practice to provide a vague explanation to the end ...


Top 50 recent answers are included