I'm trying to figure out why on one host, my CakePHP app will read/ write ciphered text in and out of a MySQL table while on another it fails. I've set up a simple test to compare....try it and you can see for yourself....
On this host it works: http://www.foldifoldi.com/cakeapps/cipher/secrets/add On this host it does not: http://cakeappcipher.aptanacloud.com/secrets/add On both hosts, the Default Character Set is "latin1" and Default Collation is "latin1_swedish_ci". On both the table type is InnoDB. Here's the two differences. 1. The foldi host is running 4.1.22-standard while the Aptana host is running Mysql 5.0.51. 2. On the foldi host, the primary key in the "secrets" table is type = PRIMARY while on the Aptana host the primary key is type = BTREE. Any insights would be greatly appreciated. Also, this is my controller: class SecretsController extends AppController { var $name = 'Secrets'; function beforeFilter() { parent::beforeFilter(); $this->pageTitle = $this->name; } function add () { if (!empty($this->data)) { $this->data['Secret']['content'] = Security::cipher($this->data ['Secret']['content'], Configure::read('Security.salt')); if($this->Secret->save($this->data)) { $this->Session->setFlash("Your secret is safe with me...."); $this->redirect(array('action' => 'confess', $this->data['Secret'] ['user_id'])); } else { $this->Session->setFlash(__('Your secret could not be created. Please review the errors below and try again.', true)); } } $this->data['Secret']['user_id'] = uniqid(); } function confess ($id) { $params = array( 'conditions' => array('Secret.user_id' => $id) ); $this->data = $this->Secret->find('first', $params); $this->set('confession', Security::cipher($this->data['Secret'] ['content'], Configure::read('Security.salt'))); } } Thanks! --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "CakePHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to cake-php+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~----------~----~----~----~------~----~------~--~---