View Encrypted String

Outputs an encrypted string using CodeIgniter’s Encrypt class. The encrypted string can then be decrypted elsewhere using view_decrypted_string This is useful for passing sensitive data through a URL.

Table of Contents

Parameters

string

This is the text you want obscured.

string="hide me"
key

This is the key that will be required to decrypt the string. When using this parameter, it’s important to note that you must use this parameter again when using the view_decrypted_string function.

key="10510158102"

Examples

{exp:cartthrob:view_encrypted_string string="hide me" key="10asl15bajkls8bb"}