Forums

How to use Joomla Registration & Profile page

jonstewart 25 Jun, 2008
Hi there,

This component is awesome creating forms with unlimited functionalities and storing/mailing the results is a breeze.

Just what I can't figure out is how to use the Joomla Registration and/or the profile page functionalities(?)

I've created a simple form that I've given restricted access to registered users only following directly after their login.

Now what I want is:

1. Keep one form entry per Joomla user

2. Display the results per user on a frontend page (could be a profile page or the form page itself)

3. The logged in user can update/edit the data through the form

So in other words: A user logs in, fills in or updates the fields and presses submit. You could call it a profile.


Can't be that difficult. I tried to display the already submitted data on the form page by using the {brackets} as suggested but only saw blanks. And I didn't understand how to keep the forms matching the particular user or how to keep the one unique entry per user. I ended up just getting more submissions in the database instead of changing the one that's already there.

The information for the registration and profile function is too limited for me to make something out of it. I'm not sure what it's supposed to do or what to fill in the fields. The help buttons also contain no information, so some sort of tutorial on this would be very helpful.

Anybody have an idea how to accomplish the fairly simple scenario outlined above?

Thanks!
GreyHead 25 Jun, 2008
Hi jonstewart,

First off the Registration PlugIn is for registering new members so that doesn't apply here.

You can create a form that recognises a user easily enough. You have to (a) check that they are logged in and (b) get their user id and load the User object (in Joomla 1.0.x it was $my, I forget the Joomla 1.5.x equivalent).

With the user info you can pre-populate your form by adding 'values' from that users record. To get the info from your extended info you'll need to look up that users record in the database table.

When they save you need to amend the Autogenerated code to Update the database record instead of adding a new record to it.

If you have some PHP and MySQL knowledge then this should be pretty straightforward.

Bob
jonstewart 25 Jun, 2008
Hi Greyhead,

Thanks very much for helping out. I wasn't sure what the registration or profile was for exactly.

I'm not that good at php/mysql. That's why I like this component so much. I know how php/mysql works and can interprete what the code does but writing code myself I haven't done yet, but willing to learn.

A) is easy, the form is only accessible when they are logged in.

B) How to load the User Object?

With the user info you can pre-populate your form by adding 'values' from that users record.



What is the standard code to do this for one form entry? I can recreate it myself for the other entries.

To get the info from your extended info you'll need to look up that users record in the database table.



Will that be the chrono form table or the joomla user table?

When they save you need to amend the Autogenerated code to Update the database record instead of adding a new record to it.



Can you tell me what to amend exactly?

If you have some PHP and MySQL knowledge then this should be pretty straightforward.



It is straightforward, and I understand what you mean, but I don't have the knowledge. Hopefully after this exercise I do!😉

I hope this is not too much trouble, but in any case thanks a ton!
jonstewart 25 Jun, 2008
I've think I found an alternative.

I installed community builder 1.2 and redirect the users to their profile page after their login where it says they need to complete all the fields.

The installation is done I just need to re-create the form with questions and answers. Should work in theory, not sure what I will be missing. Haven't really checked out the notification options yet.

I'm quite surprised there's as good as nothing out there supporting these types of profiling functionalities for Joomla.

Anyway, in case you have any more good stuff for coding it with Chronoengine, still like to hear about it.

Cheers.
This topic is locked and no more replies can be posted.