Ask a Question related to Coldfusion Database Access, Design and Development.
-
huybear@gmail.com #1
trying to obtain info from database based on username
I'm trying to forward a value(ie. username) from a logon page onto a
new page with a form in it. Pretty much, a user will be prompted with
a login page. Once he clicks submit, then the user will go onto a form
page. What I'm trying to do is make the form prefill values in the new
form by obtaining information on the username from our database. Help
me out. I'm not really fond of CF to begin with. Also, the query
command does not appear to work because it comes out as basic text
instead of an SQL command.
<cfparam name="URL.recordid" default="0">
<cfquery name="userinfo" datasource="#database#"
dbtype="ODBC" blockfactor="100" username="#USER#" password="#PASS#">
select * from members where RecordID =
#val(URL.recordid)# </cfquery>
<cfparam name="formRecordID" default="#userinfo.RecordID#*">
<cfparam name="UserID" default="#userinfo.userID#">
<cfparam name="password" default="#userinfo.password#">
<cfparam name="first_name" default="#userinfo.first_name#">
<cfparam name="last_name" default="#userinfo.last_name#">
<form name="myform"
action="bofasub.cfm?recordID=*#val(form.recordid)# " method="Post">
<input type="hidden" name="RecordID" value="#val(Form.RecordID)#">
<!--- now each form field can be its own value and will remember what
was in it when submitted --->
Field1: <input type="text" name="Field1" value="#Form.userID#"><br>
Field2: <input type="text" name="Field2"
value="#Form.password#"><br>
Field3: <input type="text" name="Field3"
value="#Form.first_name#"><br>
Field4: <input type="text" name="Field4"
value="#Form.last_name#"><br>
<input type="submit" name="#ButtonText#" value="#ButtonText#
Record">
</form>
huybear@gmail.com Guest
-
Username and password from web based authentication
Hello, I'm using web based authentication to protect some web pages. The user-id's and passwords are stored in Active Directory. I need the... -
Would like tu insert a bar chart in each row of a Datagrid based on DB info
Hi, I need to show a bar chart with the percentage of three items (total is 100%) in each row of a Datagrid based on DB information. I see two... -
Obtain VS.NET PropertyGrid's info in UITypeEditor
Hello In my custom UITypeEditor in EditValue(ITypeDescriptorContext context, IServiceProvider provider, object value) method I would like to get... -
Indenting info from database
You could use tables along with transparent GIFs to indent. -- Manohar Kamath Editor, .netBooks www.dotnetbooks.com "Dave"... -
Passing database info to page allow user input then pass into another database
Hi I really am going crazy! I'm using VBScript, ASP, and SQL My page reminds me of a shopping cart but looking at shopping cart examples has not...



Reply With Quote

