Hi,
i've read many post everywhere but they don't solve my problem.
I've created a Chronoform registration form and tested it. Now i want to call this form when an user want to register on my Joomla site. Everytime i click on Register it will display the joomla standard registration form not the chronoform registration form. I've set to "Override the Joomla Allow user registration" in the Joomla User Registration event.
can anyone help me?
Thanks.
Guido
PS: I'm using the latest version of Chronoform and Joomla ver. 2.5.6
Thanks Bob, that's a winner!
I am, however, running into a quandary... I based program code for a separate application on the way a "Chronoforms Registration" was built in the CF3. So now I need to make that same registration form in CF4. The problem is, that in your latest publication, "Build an extended User Information form", you change the way the form is indexed. In the CF3 you allowed a CF_ID field as auto-incrementing key and just inserted $user_id in to the CF_USER_ID field. In the CF4 document you changed the way to do this by extending the class and making the CF_USER_ID as the primary "non auto-incrementing" key (which is probably better, but I am too far down the road to be able to rework it this way). I am sure I don't need to do that (as I would have to rewite my other application) and it seems to save the stuff in the additional form OK, because I am using the standard JOOMLA method. But what I do need is the way to take some data from my extended registration form and "Massage" that data before it posts to the User's table.
Here is an example..
My form has..
l_name = last name
f_name = first name
reg_email = registration email
uname = username
the Joomla USERS table expects a "name" field and will error if I don't supply it. (The same is true for "email" and "username")
So I need to be able to do something like this..
<?php
$name = $f_name . " ". $l_name;
$email = $reg_email;
$username = $uname;
// I also have some hidden fields that are calculations in the extended registration form like...
$lf_name = $l_name . "," . $f_name;
$fl_name = $name;
if(empty($rct_email))
{
$rct_email = $reg_email;
}
?>
before the form is submitted to the USERS table and the REGISTRATION table.
How do I accomplish this?
A hint is all I need...
Then I will need to get the USER_ID from the newly inserted USERS record and place it into the CF_USER_ID in the registration record during the POST or ON-SUBMIT action.
How do I accomplish this?
A hint is all I need...
Thanks
Mr Fitz
Hi Mr Fitz,
You can change the data stored in the Joomla registration table by adding your PHP code inside a "Custom code" action BEFORE the "Joomla Registration" action, use this syntax:
<?php
$form->data['name'] = $form->data['f_name'].' '.$form->data['l_name'];
?>
You can then add another "DB Save" action after the Joomla registration to store the data into your custom registration table, and as long as it has a primary key, then it should work fine with the db save, you can use another custom code action to make the submitted data ready for your old table (according to what I understood).
Regards,
Max
Max, ChronoForms developer
ChronoMyAdmin: Database administration within Joomla, no phpMyAdmin needed.
ChronoMails simplifies Joomla email: newsletters, logging, and custom templates.
Thanks Bob,
That completed the picture for me.
I can get my User_ID from the Registration object for my next action.
Cool.
Thanks again
MrFitz
Hi MrFitz,
Maybe you should add a redirect code to the template file of the core joomla profile page, or, I can send you a system plugin which you will need to edit, zip then install and it would do the same, it runs on every joomla page, if a Joomla profile access is detected, then it redirects the user to the link specified.
Can be used with registration page as well.
Please contact me through the contact us page to get that if interested.
Regards,
Max
Max, ChronoForms developer
ChronoMyAdmin: Database administration within Joomla, no phpMyAdmin needed.
ChronoMails simplifies Joomla email: newsletters, logging, and custom templates.
Thanks Max....
But wouldn't this defeat the idea that we could upgrade Joomla in the future... If it was a template override like the Chrono Registration then it would not break with an upgrade???
Please explain.
Thanks in advance for your advise.
MrFitz
Hi MrFitz,
I don't think a plugin would get broken either, but I'm not sure, if you are more comfortable with the template file change and sure that it will not be overwritten then go with it๐
Regards,
Max
Max, ChronoForms developer
ChronoMyAdmin: Database administration within Joomla, no phpMyAdmin needed.
ChronoMails simplifies Joomla email: newsletters, logging, and custom templates.
I don't know either, that is why I asked you guys???
It was Bob who originally suggested and described the template override for the registration screen. I did not even know that that method existed, but after reading his FAQ it made sense. So, if you could describe the process to do a template override for this situation, it would be helpful.
Thanks
MrFitz
Ok, sorry, I didn't check all the posts,
The template override file should be under your template/html/com_users/....some place here
If it doesn't exist then you have to create it using a copy of the original one, this is something I don't know how to do and Bob may be able help you with.
You will need to inject the redirect code there:
<?php
$mainframe = JFactory::getApplication();
$mainframe->redirect('FORM URL HERE');
?>
Regards,
Max
Max, ChronoForms developer
ChronoMyAdmin: Database administration within Joomla, no phpMyAdmin needed.
ChronoMails simplifies Joomla email: newsletters, logging, and custom templates.
Hi The Fitz,
I took a quick look at the Joomla! Log-in code and don't see any obvious explanation for this behaviour on first log-in. It might be built into your template as a redirect to the new User Profile form ???
Bob