Hi,
I created a V4 user registration form. All works fine, but now I want to redirect the 'register'-link on the Login-page to this new form instead of the http://sitename.com/index.php/login/register it links to now.
Somewhere on the forum I read that I should change something in de php code in Joomla? Or do a 'template override'? But I don't know what that is.
Thanks!
I created a V4 user registration form. All works fine, but now I want to redirect the 'register'-link on the Login-page to this new form instead of the http://sitename.com/index.php/login/register it links to now.
Somewhere on the forum I read that I should change something in de php code in Joomla? Or do a 'template override'? But I don't know what that is.
Thanks!
Hi InternEd,
A Template Override is the best way to of this. In short you can put a folder in your template/html folder that will automatically over-ride any component view. See here.
In this case you want to over-ride com_user/register to redirect to your form.
Bob
A Template Override is the best way to of this. In short you can put a folder in your template/html folder that will automatically over-ride any component view. See here.
In this case you want to over-ride com_user/register to redirect to your form.
Bob
i am trying to achieve this in a joomla 2.5 installation and cf4 but don t get it to work. my guess is that the paths and the com structure has changed somewhat in newer joomla version.
installed com_users now holds views/registration/tmpl/default.php and some other files. I copied that structure under my template/html folder but it does not seem to pick up the redirect?
installed com_users now holds views/registration/tmpl/default.php and some other files. I copied that structure under my template/html folder but it does not seem to pick up the redirect?
hi Bob, thank you for your response. However I think I need to clarify a bit more. The faq you are pointing to in exactly the one that I used to setup the template override. But the problem is that I cannot replicate everything. The FAQ states to copy components/com_users/registration/default.php to the templates folder. However my J2.5 install does not hold such a folder. I have components/com_users/views/registration.... and that folder does not hold a default.php file. underneath that registration folder is another folder /tmpl/.. and there is a default.php
So what I did is copy that com_users structure from the original location to my template location. so there i now have /templates/mytemplate/html/com_users/views/registration/tmpl/default.php
That php file contains the code from the faq with the redirect to my cg registration form... however that form does not get picked up on the front end. Joomla still points to the default reg form..
I even tried to copy also the other files in the original registration and view folders to the template location but to no avail....😟
any idea with this extra info? the cf install itself looks fine to me, a contact form displays fine in the front end....
So what I did is copy that com_users structure from the original location to my template location. so there i now have /templates/mytemplate/html/com_users/views/registration/tmpl/default.php
That php file contains the code from the faq with the redirect to my cg registration form... however that form does not get picked up on the front end. Joomla still points to the default reg form..
I even tried to copy also the other files in the original registration and view folders to the template location but to no avail....😟
any idea with this extra info? the cf install itself looks fine to me, a contact form displays fine in the front end....
Hi jdekempenaer,
I'm sorry, the FAQ had the wrong paths :-( I've updated it now.
The path structure in the template folder is different from the extension path - the file needs to be
Hopefully that will then work OK. I have certainly used this method successfully.
Bob
I'm sorry, the FAQ had the wrong paths :-( I've updated it now.
The path structure in the template folder is different from the extension path - the file needs to be
/templates/mytemplate/html/com_users/registration/default.php
without the /views/ or /tmpl/ parts Hopefully that will then work OK. I have certainly used this method successfully.
Bob
yup that's it. works like a charm now! thx
This topic is locked and no more replies can be posted.