this question is really about bad practice when it comes to PHP. I'm learning how to code in this language and I can already code in Lua & Python. When an if statement is told to "do nothing" in Lua, you would literally just say "return", but I understand that doesn't work in PHP. I've been using print() instead, but I understand that's probably bad practice and I was wondering if there was a function for doing nothing.
if (condition) { //If condition is met
print(""); //Do Nothing
} else {
//Run the function;
}
Thank you in advance.
Aucun commentaire:
Enregistrer un commentaire