Link | xs_genPwd(9) |
Author | Jonathan Guthrie |
Category | Action |
Version | 9.x |
License | Public Domain |
Posted | 18 Sep 2012 |
Updated | 18 Sep 2012 |
More by this author... |
Generates a random password of a given size.
local(newPassword = xs_genPwd(20))
Click the "Download" button below to retrieve a copy of this tag, including the complete documentation and sample usage shown on this page. Place the downloaded ".inc" file in your LassoStartup folder, restart Lasso, and you can begin using this tag immediately.
// ================================== /* xs_genPwd Creates a random password */ // ================================== define xs_genPwd(size::integer=8) => { local(pMap = array('a','b','c','d','e','f','g','h','i','j','k','l','m','n','o','p','q','r','s','t','u','v','w','x','y','z','A','B','C','D','E','F','G','H','I','J','K','L','M','N','O','P','Q','R','S','T','U','V','W','X','Y','Z','1','2','3','4','5','6','7','8','9','0')) local(thisPwd = string) loop(#size) => { #thisPwd->append(#pMap->get(integer_random(#pMap->size,1))) } return #thisPwd }
No comments
©LassoSoft Inc 2015 | Web Development by Treefrog Inc | Privacy | Legal terms and Shipping | Contact LassoSoft