I get the variable \'stock\' from my database. I would like increment my variable with an update with this code:
$stock = $_POST[\'stock\'] $nom = \'salade\'; $
You can use like this for variable in text query.
$req= ("UPDATE ingredients SET stock='".($stock+1)."' WHERE nom = :nom;");