6 years ago a guy looked at me face to face, and boldly told me; "I don't like you!" I immediately fired a response, I asked him that day; "Thank you for the honest feedback, but those that you like, how has it made their life better? How does your liking people pay their bills or take a bank loan? My brother keep your like, I need God's like And that's what guarantees my future. Today I joined a CEO friend of mine in an interview Panel to recruit some new staff, it was a long session, as we returned from a coffee break to continue the hectic interview session, here was this same guy walked in with his grey jacket and CV coming for the interview. Our eyes kissed by fluke, we immediately recognised each other; "the world is indeed spherical", I soliloquized. He felt very uncomfortable through out the interview, one could clearly see the volcanic eruption ongoing in his whole nervous system, he even mistook his date of birth for his last date of empl...
am registering users via csv file. I get user details, then save them in the usual users table using the
JUser
class. What is not working are extra columns I have. I've created them in the db already. My code is as below$pass = 'xxxxxxx'; //default $data = array( "name"=>$allnew[$i]->name, "username"=>$allnew[$i]->username, "password"=>$pass, "password2"=>$pass, "email"=>$allnew[$i]->email, "telephone"=>$allnew[$i]->telephone, "test"=>strtolower($allnew[$i]->test), "test1"=>$allnew[$i]->test1, "gid"=>18, "usertype"=>$newUsertype ); $userr = new JUser; if(!$userr->bind($data)) { throw new Exception("Could not bind data. Error: " . $userr->getError()); } $userr->set('id', 0); $userr->set('usertype', $newUsertype); $userr->set('gid', $authorize->get_group_id( '', $newUsertype, 'ARO' )); $date =& JFactory::getDate(); $userr->set('registerDate', $date->toMySQL()); $userr->set('leavedays', $data['leavedays']); $useractivation = $usersConfig->get( 'useractivation' ); if ($useractivation == '1') { jimport('joomla.user.helper'); $userr->set('activation',$pass ); $userr->set('block', '1'); } if($userr->save()) { echo ' Success'; } else { echo 'error'; }
please help.
test
and test1
are not being saved and I can't tell why. both columns exist in the database.
Comments
Post a Comment
Your say...