Posts from PHP

A simple two-way function to encrypt or decrypt a string

This function will provide you a two-way system to encrypt a string or decrypt an encrypted string. /** * Encrypt and decrypt * * @author Nazmul Ahsan * @link * * @param string $string string to be encrypted/decrypted * @param string $action what to do with this? e for encrypt, d for decrypt */ function my_simple_crypt( $string, $action = 'e' ) { // you may change these values to your own $secret_key = 'my_simple_secret_key'; $secret_iv = 'my_simple_secret_iv'; $output = false; $encrypt_method = "AES-256-CBC"; $key = hash( 'sha256', $secret_key ); $iv = substr( hash( 'sha256', $secret_iv ), 0, 16 ); Read more


WPpeople works mainly on WordPress based projects.
It specializes in developing Plugins, Themes and WP based apps. Well, you can count SEO and maintenance jobs too.

Get in touch