+1 vote
ago by
Hello;) How to make so when you press the buttons "Save" preserved the text of the cookie? When you update the page you saved it already..
Here's an example: 8ee6332d618246c7bc5acc33aa6b39fd.PNG
<input type="tel" placeholder="Введите номер QIWI кошелька" id="qiwinumber" maxlength="12" class="qiwinumber" onclick="StartValue();" />
<input type="submit" class="saveqiwinumber" value="Сохранить"/>
ago by
The question is too General. Where is the text before pressing the button? Where it needs to be preserved?

2 Answers

0 votes
ago by
document.cookie = "userName=Vasya";
but if you don't know what to do with it freelansim.ru
+1 vote
ago by
you can use PHP Cookie php.net/manual/ru/function.setcookie.php
or jQuery jQuery plugin.cookie plugins.jquery.com/cookie
But when the page loads, if Cookie is something there, then output in the form
ago by
Could you give examples?
...