PHP code example of aufa / encryption
1. Go to this page and download the library: Download aufa/encryption library. Choose the download type require. 2. Extract the ZIP file and open the index.php. 3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
aufa / encryption example snippets
/**
* Using default encryption mcrypt
*/
Aufa\Encryption\Encryption::encrypt('string to encrypt', 'saltkey');
/**
* Using alternative type
*/
Aufa\Encryption\Encryption::altEncrypt('string to encrypt', 'saltkey');
/**
* Decrypt encrypted string with auto detect encryption use
*/
Aufa\Encryption\Encryption::decrypt('string to decrypt', 'saltkey');
// or can use
Aufa\Encryption\Encryption::altDecrypt('string to decrypt', 'saltkey');