Hi,
So far, I've been using Drupal pretty much out-of-the-box. New content created by a user gets automatically associated with the user creating it -- everything just works.
I'm taking the next steps and 'extending'. I wrote a module that pulls some info from the filesystem, presents it to the user, and gets them to select an item from a pulldown menu.
In the module, I put the data I retrieve into a $_SESSION['test_data'] variable, and the result of their menu selection into $SESSION['test_select'] and use both during their session. That works like I expect.
Now, I want to add that data to the User's permanent record in the database. What I'm looking to do is:
For the currently logged-in user, what's the value of 'test_data' and their selection of 'test_select', once they've MADE the selection, permanenetly add/record both pieces of data to their data record.
I've got a real basic understanding question --
Before I add the data for the User, I have to create the record type in the database, right? How do I do that? Do I have to do that outside of Drupal 1st, using mysql database admin? Do I do that using an API?
A simple example of how to programatically
(a) create a record type in the DB
(b) add the data to the user's record