Ultimately, this is what I hope to accomplish:
I would like my customers to be able to go to my form and insert their account number and last name, then if it is in the database, have all of their info (name,address,balance,charges,etc) automatically show up. Then I would want them to have the option to make a payment, request additional service, etc without them having to enter all of their info again.
I can load data into the database pretty easily but getting it out and displaying it is where I am stuck.
Getting the data out of the database is done behind the scenes, but to display it you need to use the code, there is no way the form can expect which fields you want to display or how you want your page formatted!
But if you are loading a 1 record only per customer AND if your form fields names match the columns names loaded then you should not need to use or alter any code, this is explained in the "record loader" tutorial.
Regards,
Max
Getting the data out of the database is done behind the scenes, but to display it you need to use the code, there is no way the form can expect which fields you want to display or how you want your page formatted!
I understand that but it would be great if there was another dropdown to select which DB id from the selected table to insert into a particular form field id. Also, if it was possible to insert some DB data into an article through a plugin, that would be way cool and easy to display DB data.
But if you are loading a 1 record only per customer AND if your form fields names match the columns names loaded then you should not need to use or alter any code, this is explained in the "record loader" tutorial.
I going to have to re-read it. But it is a little hard for me to follow on how to only allow a person to view their info. For example the tutorial says insert token in the param field. I think a token is a secret key when a person logs on. Is that correct?
I guess what I would really like to know is, is it possible to do what I am trying to accomplish (first post) without knowing code?
What you describe is not difficult to do with ChronoForms, but it's not dead simple either.
Can you do it without knowing any PHP or MySQL - IMHO probably not.
Bob
Sincerely, thanks for your help guys!
Gabe
The DB Record Loader will do most of the work for you. There is a tutorial in the downaloads area here I think.
Bob
The DB Record Loader will do most of the work for you. There is a tutorial in the downaloads area here I think.
Thanks for the reply. There is a tutorial but I just don't understand had to pass the "token" or any request param value to DB recoed loader. I think token only works if a request was sent via email???
Gabe
Put this code in the "WHERE" box of the DB Record Loader and leave the db field or request param blank. It works!
<?php
$user = &JFactory::getUser();
echo "cf_user_id = ".$user->id
?>
