daily pastebin goal
92%
SHARE
TWEET

JS functions

a guest Jan 11th, 2018 81 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. function checkLogin(login)
  2. {
  3.     golos.api.getAccounts([login], function(err, response){
  4.         if(response == '')
  5.         {
  6.             document.getElementById('login').value = '';
  7.             return false;
  8.         }
  9.         return true;
  10.     });
  11.  
  12. }
  13.  
  14. function storeKeyLocally()
  15. {
  16.     var login = document.getElementById("login").value;
  17.     var key = document.getElementById("key").value;
  18.     if(key && login)
  19.     {
  20.         localStorage.setItem(login, sjcl.encrypt(login, key));
  21.         localStorage.setItem('login', login);
  22.         return true;
  23.     }      
  24.     else
  25.     {
  26.         return false;
  27.     }
  28. }
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top