I have a test app on localhost and a duplicate on a real server. Its
sole purpose is to take textarea input and save it to a single MySQL
table, along with arbitrary input not from a form. The web server
version can be found at http://www.spamguy.org/cakeapps/testcake/things/add
.
On localhost, save() only saves what it finds in POST. On the
webserver, it'll save whatever I tell it to.
function add()
{
$data = $this -> data;
if (!empty($data))
{
$data['Thing']['public_id'] = mt_rand();
debug($data, true, true);
$this -> Thing -> save($data);
}
}
On localhost, public_id doesn't appear in any INSERT statements
because it wasn't part of POST. Despite that, the output of debug() is
the same:
Array
(
[Thing] => Array
(
[blah] => (correct text value)
[public_id] => (output from mt_rand())
)
)
What's going on? Thanks.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"CakePHP" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/cake-php?hl=en
-~----------~----~----~----~------~----~------~--~---