[eluser]TWP Marketing[/eluser]
I would just make a new method in your User model, perhaps called "create_user($data)"
You have the information from your form, just pass it to the model function.
I don't know exactly what you have in your variable $random_stuff,
but you ought to be able to define a default set of that var content
when you create a new user record.
You can make a model method to generate the default content for a new user
record, which would include the $random_stuff var.
For instance, in your model:
Code:
public function default_user()
{
$user_data = array();
$user_data['name'] = "";
$user_data['type'] = "s"; // standard or default user type
$user_data['random_stuff'] = $this->set_random_stuff();
return($user_data);
}
public function set_random_stuff()
{
$stuff = array();
$stuff['var_name'] = 'some name';
$stuff['some_other_stuff'] = 'more stuff here';
return( $stuff );
}
Does this answer your question? Please ask for again if I missed your point.