After a few attempts I still cant get it to work.
In the webloginpe.class.php you can find at line 601 the following code:
$newUserAttr = "INSERT INTO ".$web_user_attributes.
" (internalKey, fullname, email, phone, mobilephone, dob, gender, country, state, zip, fax, photo, comment) VALUES".
" ('".$key."', '".$fullname."', '".$email."', '".$phone."', '".$mobilephone."', '".$dob."', '".$gender."', '".$country."', '".$state."', '".$zip."', '".$fax."', '".$photo."', '".$comment."')";
$insertUserAttr = $modx->db->query($newUserAttr);
I tried to modify it to the following code
$newUserAttr = "INSERT INTO ".$web_user_attributes.
" (internalKey, fullname, email, phone, mobilephone, dob, gender, country, state, zip, fax, photo, comment) VALUES".
" ('".$key."', '".$fullname."', '".$email."', '".$phone."', '".$mobilephone."', '".$dob."', '".$gender."', '".$country."', '".$state."', '".$zip."', '".$fax."', '".$photo."', '".$comment."')";
$insertUserAttr = $modx->db->query($newUserAttr);
// ADDED THE STUFF BELOW
$newUserAttr = "INSERT INTO ".$web_projects.
" (internalKey, company_id, project_name) VALUES".
" ('".$key."', '".$company_id."', '".$project_name."')";
$insertUserAttr = $modx->db->query($newUserAttr);
I’ve added the following code below line 428
$company_id = $modx->db->escape($modx->stripTags($_POST['company_id']));
$project_name = $modx->db->escape($modx->stripTags($_POST['project_name']));
And it’s not working

. This is what the sql outputs at submitting the registration form
MODx encountered the following error while attempting to parse the requested resource:
« Execution of a query to the database failed - You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '(internalKey, company_id, project_name) VALUES ('10', '', 'Project naam')' at line 1 »
SQL: INSERT INTO (internalKey, company_id, project_name) VALUES ('10', '', 'Project naam')
Hope someone can help me out on this one
Rogier