How do I set a computed value in a form in a view that I can read after form submission?
Either I have the concept wrong, the function wrong or something else.
I've got a view with form input
some of wording of the form input is based on a random value, and I need to know the random value that was set after the form is submitted.
I want to set the random value in the form
$myrand = rand(1,9);
with both of these below: (not sure if this the correct way or which one is correct).
echo $this->Form->Hidden('MyResult', $myrand);
then I want to read the result in an function in the plugin
the dump of " $Sender->EventArguments['User']['MyResult'] " is always string ""
I may not provide the completed solution you might desire, but I do try to provide honest suggestions to help you solve your issue.