Apply for Zend Framework Certification Training

Codeigniter






Encryption and Decryption In CodeIgniter

Step - 1

To initialize the encryption class one must have to load the library as shown below:
$this->load->library('encrypt');

For setting up your key, go to application/config/config.php, open the file and set:

$config['encryption_key'] = "YOUR KEY";

Below we have created an example to show, how to encode and decode the data.

To encode the code we have used below syntax:

$this->encrypt->encode() // Performs the data encryption and returns it as a string

To decode the code use:

$this->encrypt->decode() // Decrypts an encoded string.

 

 

< How to use custom hook points with CodeIgniter | webphplearn Chirata (Swertia Chirata) Benefits and Side Effects in Hindi >



Ask a question



  • Question:
    {{questionlistdata.blog_question_description}}
    • Answer:
      {{answer.blog_answer_description  }}
    Replay to Question


Back to Top