Forums

User Modify Data on Form

goodoboy 09 Mar, 2011
Hello, I read the ChronoConnectivity details and what this component can do, but I just wanted to confirm if this component can meet my needs before going futher. I am still sorta green/new to Joomla, so I apologize in advance if my question seems simple. I apologize if this is too lengthy.

I plan to use ChronoForms to create a form similar to http://quizlet.com/create_set/ and I already know custom scripting is required for registered users to add/delete rows as needed. I am ok with this and this seems doable.

My questions are can I use ChronoConnectivity for after users have created their data and submitted form to the database to do the following:

1. Can users edit/delete/add data to the form and save the data back to the same database table? Or will a new table be created? How will users view their listed forms submissions?

2. Can a module or seperate webapage be show the list of form submissions for the user? See picture below for example. When a user submits a form, they will put a title on the form and I want that title(s) to be shown as a list on a module or separate webpage for all the forms the user submitted. Is there any example of this with ChronoConnectivity? ? I am building a flashcard website they require users to enter information (terms and answers) in a form and save in database for a separate application to pull this data from the database and create the flashcard. I wanted the user profile page to show a list of all the forms (or flashcards) they created.
3. I need the ability for the user list to be viewed by registered users as well. Extra programming required for this?

4. Can only partial data from the user form be shown? Like just the title of the page.

I hope my questions are not too complex and feel free to offer comments/questions/suggestions. I hope this component is what I been searching for.

Thanks alot
GreyHead 10 Mar, 2011
Hi goodoboy,

The answer to all of your questions is 'yes', but with the qualification that each of these things will require some coding.

Basically use a ChronoForm to create, display or edit a single record from a database table (or tables). Use ChronoConnectivity to display a list of records from a table and to show links to forms that let the user display, edit or delete an individual record.

Bob
goodoboy 10 Mar, 2011
Thanks Bob,

Thats exactly what I needed to know. Now, I will jump in and get my hands dirty. Well, atleast get the form created/modified as I need. Then submit the form and edit/delete/add data for practice.

Thanks alot. If I have any questions I will respond. I will be sure to validate this component once Im up and running.
GreyHead 10 Mar, 2011
Hi goodoby,

I suggest that you start with a very simple test form to get the hang of ChronoForms. Once you understand how the bits fit together then more complex forms will be easier. It's generally a mistake to start out with a complex form as there are two may things that are interacting.

Bob
goodoboy 10 Mar, 2011
Thank you Bob,

I already created the form. That was pretty easy. See picture below.

My question is: After the registerd user submits the form, can a listing (showing the title entry only) automatically generate without me (the admin) having to create the a listing in the Joomla admin area with ChronoConnectivity? I am not sure if additionally programming is required for this to happen. If so, can you please lead me in the right direction. I bought you beer🤣 🤣 cause you have been very helpful. I can add buttons next to listing for add/delete/edit data in the form.

I'm thinking I have use to ChronoConnectivity to create a listing for each form the registered user creates. This is not something I wanted to do. But I am not sure how to generate a listing automatically after the user submits the form without me having create it.

Thanks alot Bob. I think once I get some direction on this, I will be at ease.

Thanks,
GreyHead 10 Mar, 2011
Hi goodoboy,

OK, first you need a table to save the form data and a DB Connection for the form if you haven't already created them.

There's a tutorial from he link above, it's a bit out of date but more or less right. Just remember that when you create a table you meed to make sure that all the bars that you want to create are *green* (when you start they are mostly red).

Once data from the form is saving there is a simple data viewer in the Admin area.

If you need something more than that then a ChronoConnectivity listing in the front-end is the way to go. This gives you much more control over display and layout.

Bob
goodoboy 10 Mar, 2011
Thanks Bob,

After the user submits the form, can ChronoConnectivity automatically create that user listing without me doing anyting in the backend?

Thanks,
GreyHead 10 Mar, 2011
Hi goodoboy,

Yes, once the ChronoConnectivity Listing is set up it will automatically display whatever is in the database table.

Bob
goodoboy 10 Mar, 2011
Thanks Bob,

I notice what I am trying to do is already show on under the Users' Stories Tab on this website. I played that for minute. I think the admin needs to approved my article submission.

Thanks.
goodoboy 11 Mar, 2011
Bob,

So far, I created a form and connected the form to one database table. I submitted a few forms in the database with some data. I installed ChronoConnectivity and can display some of the fields on a webpage. So, I'm making progress. I can use HTML to later make the display look pretty, etc.

My next question is:

1. How can I use ChronoConnectivity to display a registered user listing of records only for one form? Lets use goodoboy for example as a registered user. I only want goodoboy to see his listings of data he submitted. Only one form will be used by everyone, but I want each user to view his/her own listing of data submitted. I'm trying to setup a "My Profile" where goodoboy can only view/edit/add/delete his listing of records from the database. Each registered user profile will only show that user's listing, not all the listing submitted to the database as it currently shows. I haven't figured out how I will setup a My Profile page for each user, maybe I use Joomsocial Profile page (and just disable all the extra features). Please let me know if this is doable. Please see example in the picture. User polkadot3600 have his own listing of what he created only. I wanted to have a delete/edit buttons next to each title.

Again, thanks for the help and I am learning alot. Please add any suggestions/comments.

Thanks.
GreyHead 11 Mar, 2011
Hi goodoboy,

If you haven't already seen them there are a series of ChronoConnectivity tutorials on my site here

You manage which records are displayed with the ChronoConnectivity WHERE and Header boxes.

To restrict display to logged in users add this to the beginning of the Header Box
<?php
$user =& JFactory::getUser();
if ( !$user->id ) (
  global $mainframe;
  $mainframe->redirect('index.php', 'Please log in to see this page');
}
?>
You can change the redirect URL and message to suit your site.

To show users their own entries you mush have a user identifier in the record, if you created the table with ChronoForms this will be the cf_user_id column.

The WHERE Box code is
<?php
$user =& JFactory::getUser();
echo "WHERE `cf_user_id` = {$user->id} ";
?>
Note: you will need slightly different syntax here if you are using more thant one filter -- see the tutorials.

Bob
goodoboy 11 Mar, 2011
Thanks Bob.

I will go and try this for one user. I just want each user to add entires to their own listing. Each user will have a profile page where they can view all their entries and delete/edit/modify their entries (or the form) as needed.

Everyone (registered or not) can go to a user profile page to see the entries.

I will let you know what happens.

Thanks alot.
GreyHead 11 Mar, 2011
Hi goodoboy,

Even if the user only sees their own records there is a very strong argument to save all the records for all users in the same database table.

I'm not clear if you are doing this or not but thought it worth mentioning.

Bob
goodoboy 11 Mar, 2011

Hi goodoboy,

Even if the user only sees their own records there is a very strong argument to save all the records for all users in the same database table.

I'm not clear if you are doing this or not but thought it worth mentioning.

Bob



Yes, this is something I need to do. Each user record needs to be saved in a database table. I am developing a website where user can store their on flashcard sets. A flashcard application will pull the user record from the database and create a flash based flashcards. Similar to this: http://quizlet.com/1848396/ch-4-introduction-to-atoms-flash-cards/

Right now I am not sure if Chronoforms and ChronoConnectivity can help me accomplish storing a database table for each user who wants to store their own records and list these records in their profiles. All this must be done automatically without me doing any work in back end of Joomla.

Is this possible?

Thank you Bob.
goodoboy 11 Mar, 2011

there is a very strong argument to save all the records for all users in the same database table.

Bob




Hello Bob,

So is this not possible? I'm not a MySQL expert. I think it is better for each user to have their own table.

All users will use the same form to store their data. The amount of users can reach 100k eventually.

Thanks
GreyHead 11 Mar, 2011
Hi goodoboy,

Still better to use a single table, you don't want to end up maintaining a database with 100,000 small(ish) tables. One table with a few hundred thousand records isn't much of a problem.

Bob
goodoboy 12 Mar, 2011
Thanks Bob,

Great to know I can use one table for many records.

I think I am confusing myself. Hopefully you can get me back straight. I know with ChronoConnectivity I can display any record in the database table wherever I choose. I can do this with one ChronoConnectivity link. Currently, I have listing showing listing of records added to the database tables.

Here where I don't know if I can do: When a new user register for the site, creates a record, how can a record listing for that user automatically show in the user profile page? For now, lets just say the user profile is just a webpage on my website I have setup for practice. I have not figured out how I will get a user profile setup yet.

So thats what I need to know is ChronoConnectivity can do. I searched the forums, but no luck finding a case like this what I need to do. I just need way for a listing to automatically generate when a new registered user creates a record with the form and for this new listing to generate on a the user profile page. For practice, i can just use any webpage on the site to represent the user profile page.

Thanks again Bob, I know I have alot of questions but I just want to be sure I know what I am doing.

Thanks
GreyHead 12 Mar, 2011
Hi goodoboy,

I'm not very clear what a user profile looks like in this case.

If you are usign ChronoConnectivity then it has to be on its own page -- there is no module or plug-in for CC at the moment.

If the profile is a list of records (possibly with some static data like the username) then that can be done in CC.

If ther is no list of records involved then ChronoForms may be the better approach.

Bob
goodoboy 12 Mar, 2011

Hi goodoboy,
I'm not very clear what a user profile looks like in this case.



Thanks Bob for your help. Let me explain what I mean by user profile (same thing as member profile) in my case. The member profile may be created from a component, not sure yet. Just think of the user profile as your own facebook page.

My website allow students to create flashcards (questions and answers will be data enter on the form). Each student will have their own Profile page that shows their: username, education level, and a list of all the flashcards they created. See picture below for an example user profile page. The flashcards data are created by the form using CF. Does this help?

If you are usign ChronoConnectivity then it has to be on its own page -- there is no module or plug-in for CC at the moment.

I don't think CF can help me to display a listing for each member profile because CC has its own page (or link). Am I correct? I may have to include this in a customize member profile component that can get the user entries from the database and then display these entries in a list on each member profile page.

However, I can use CC to show the latest form submissions (showing the username, title, date). Hopefully, I can show list in a module named "Latest Activity", instead of displaying on separate webpage or link.

Thanks for your help and I await your reply. Let me know if my assumptions are correct and I think I will be in the right direction.

Thank you alot.
GreyHead 12 Mar, 2011
Hi goodoboy,

You could create this profile in either ChronoForms or ChronoConnectivity. I'd probably used a ChronoForm as there is more layout flexibility (the tradeoff is a little more coding).

Those pages do have their own URL -- I'm not clear how that is a problem. You can always get the current User ID and hence their info and records from the Joomla! User Object.

Bob
goodoboy 12 Mar, 2011

Hi goodoboy,

You could create this profile in either ChronoForms or ChronoConnectivity. I'd probably used a ChronoForm as there is more layout flexibility (the tradeoff is a little more coding).

Those pages do have their own URL -- I'm not clear how that is a problem. You can always get the current User ID and hence their info and records from the Joomla! User Object.

Bob



Thanks Bob,

The member profile page must automatically generate once the user is registered. I'm not sure how I can setup ChronoForms or ChronoConnectivity to perform this action without me having to manually create a member profile in the backend each time a user register. I'm trying to think, but I can't picture this. Currently, I have it setup now, where registered users can use the form to enter records to the database via ChronoForms.

How can I use ChronoForms to setup a member profile page with their own URL automatically when a user register? Similar to the picture above. I need this profile to automatically generate once the user is registered, similar to if I register as a member of facebook or Chronoengine Forums.

If I can figure out this problem, then I think I am on the right track.

Thanks for your help and I apologize for all the questions but I'm just trying to think and plan.
GreyHead 12 Mar, 2011
Hi goodoboy,

You don't have to set anything up for a new user. You set up *one* form/listing that checks the User ID and shows the data for that user.

Bob
goodoboy 13 Mar, 2011
Thanks Bob,

Great to read. So this is doable and I don't have to go trying to modify an existing Joomla social networking component (like Jomsocial) to accomplish the task of a member profile page. This is getting challenging.

I'm trying to think which method will be better and easier and quickest. Using ChronoForms and Chronoconnectivity or Jomsocial to setup a User Profile page. Both methods I will have to pay a PHP programmer to code what I want. Unless somewhere in the forums this task has been done before.

With Jomsocial, the My Profile just need to be custome modified to show the listing along with other items.

Thanks

Im really stuck between the two. But I am happy to know that this can be done using CF and CC.
GreyHead 13 Mar, 2011
Hi goodoboy,

I really don't know JomSocial well enough to have a useful view on this choice :-(

Good luck

Bob
goodoboy 14 Mar, 2011
Thanks Bob,

Thanks for all your support. I am currently in thinking stage and decided how to implement my plan. If I have any questions, I will return. Thank you.
This topic is locked and no more replies can be posted.