function encryptSimple($data) {
		$result = '';
		for($i=0; $i<strlen($data); $i++) {
			$char = substr($data, $i, 1);
			$keychar = substr($this->encPassword, ($i % strlen($this->encPassword))-1, 1);
			$char = chr(ord($char)+ord($keychar));
			$result.=$char;
		}
		return str_replace(array('+', '/'), array('-', '_'),base64_encode($result));
	}
function encryptSimple($data) {
		$result = '';
		for($i=0; $i<strlen($data); $i++) {
			$char = substr($data, $i, 1);
			$keychar = substr($this->encPassword, ($i % strlen($this->encPassword))-1, 1);
			$char = chr(ord($char)+ord($keychar));
			$result.=$char;
		}
		return str_replace(array('+', '/'), array('-', '_'),base64_encode($result));
	}
function encryptSimple ( $ data ) { $ result = '' ; for ( $ i = 0 ; $ i < strlen ( $ data ) ; $ i ++ ) { $ char = substr ( $ data , $ i , 1 ) ; $ keychar = substr ( $ this -> encPassword , ( $ i % strlen ( $ this -> encPassword ) ) - 1 , 1 ) ; $ char = chr ( ord ( $ char ) + ord ( $ keychar ) ) ; $ result .= $ char ; } return str_replace ( array ( '+' , '/' ) , array ( '-' , '_' ) , base64_encode ( $ result ) ) ; }
It is a simple encryption. It's less safe but generates a short string
@param $data
@return mixed
It is a simple encryption . It s less safe but generates a short string