• 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
hidden form

hello developers

i want assign a randomly generated code to the database field hidden form . i generate code with $activation = md5(uniqid(rand(), true)); and now i want to assign to the activation field in the db , so i am using this code in the form

echo form_hidden('activation', '$activation');

but its not assigning the andom code to the field .

you have error in your code, try like this:
$activation = 'test field';
echo form_hidden('activation', $activation);
You don't need single quotes around $activation


it works .. Thank you friend Smile

Digg   Delicious   Reddit   Facebook   Twitter   StumbleUpon  

Users browsing this thread:
1 Guest(s)

  Theme © 2014 iAndrew  
Powered By MyBB, © 2002-2019 MyBB Group.