Posts by pmichelazzo • 11 points
4 posts
-
0
votes2
answers650
viewsA: Add 1 month function in php fails when current month has no day 31
First, the question is: what "adding 1 month". 1 month = 30 days? 28 days? 29 days? 31? The following code: echo date("Y-m-d", strtotime("2019-01-31 +1 month")); It has the following result:…
phpanswered pmichelazzo 11 -
1
votes2
answers905
viewsA: Should I treat emails as case sensitive or insensitive?
Specification or recommendation considered universal is the RFC (as well pointed out). The remainder and any other approach goes to the taste of the customer. If you send an email to Apple servers…
-
0
votes4
answers93
viewsA: Enable input type="file" when input type="checkbox" == true
A little simpler: function clique() { var e = document.getElementById("imagem"); e.removeAttribute("disabled"); } <p>Checkbox: <input type="checkbox" name="check"…
-
0
votes1
answer31
viewsA: Losing value of POST fields when user connection is slow
Take the test in the post before you put it in the bank: if (!empty($_POST)) { // coloque seu codigo aqui; } else { // devolva para o usuário uma mensagem ou retorne para o form; } Greetings…