File: testplugin.php

Recommend this page to a friend!
  Classes of zinsou A.A.E.Moïse   jQuery Friendly Password Suggest   testplugin.php   Download  
File: testplugin.php
Role: Auxiliary data
Content type: text/plain
Description: PHP example file to handle ajax call during the generation process
Class: jQuery Friendly Password Suggest
Suggest passwords based on what the user typed
Author: By
Last change:
Date: 6 years ago
Size: 677 bytes
 

Contents

Class file image Download
<?php require_once('CntrctRs.php'); $_GET=array_map('trim',$_GET); if(isset($_GET['prefix'])){ $length=intval($_GET['length']); $prefix=htmlspecialchars($_GET['prefix']); $number=intval($_GET['number']); $responsetype=(string)$_GET['responsetype']; unset($_GET['prefix']); unset($_GET['length']); unset($_GET['number']); unset($_GET['responsetype']); $_GET=array_map('htmlspecialchars',$_GET); $x=new FriendlyPwdSuggest($_GET,$length,$prefix,false); if($responsetype==='json') echo $x->suggest_n($number,$responsetype); else foreach ($x->suggest_n($number,$responsetype)as $v) echo $v.PHP_EOL .'<br>'; }else echo false; ?>