Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Shaun E on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Just get a Blank form

Status
Not open for further replies.

roropacific

IS-IT--Management
Jun 29, 2002
23
US
Hello
I have created this form for output I do not get any results. What I am doing wrong?
I have a different form that works fine.

<html>

<head>
<meta HTTP-EQUIV=&quot;Content-Type&quot; CONTENT=&quot;TEXT&quot;/html; charset=windows-1252&quot;>
<meta HTTP-EQUIV=&quot;Content-Language&quot; CONTENT=&quot;en-us&quot;>
<title>Customer Service FeedBack Form</title>
</head>

<body>

<h1>Customer Service FeedBack Form</h1>






<FORM method=&quot;post&quot; action=&quot;insertdata.cfm&quot;>
<li>
<p><em>Service Agent</em>
<input TYPE=&quot;TEXT&quot; NAME=&quot;user_name&quot; SIZE=&quot;25&quot;></p>
<li>
<p><em>Model Number</em>
<input TYPE=&quot;TEXT&quot; NAME=&quot;Product_Model&quot; SIZE=&quot;25&quot;></p>


<li>
<p>Issue Title</p>
<p><TEXTAREA name=Summary cols=35></TEXTAREA><br>
</p>
<li>
<p>Issue Description</p>
<p><TEXTAREA name=Description rows=5 cols=35></TEXTAREA><br>
</p>
<li>
<p>Please provide the following contact information:</p>

<p><em>First Name</em>
<input type=&quot;TEXT&quot; NAME=&quot;Contact_FirstName&quot; SIZE=&quot;25&quot;></p>

<p><em>Last Name</em></td>
<input type=&quot;TEXT&quot; NAME=&quot;Contact_LastName&quot; SIZE=&quot;25&quot;></p>
<p><em>Street Address</em>
<input type=&quot;TEXT&quot; NAME=&quot;Contact_StreetAddress&quot; SIZE=&quot;25&quot;></p>
<p><em>Address (cont.)</em>
<p><input type=&quot;TEXT&quot; NAME=&quot;Contact_Address2&quot; SIZE=&quot;25&quot;></p>
<p><em>City</em>
<input type=&quot;TEXT&quot; NAME=&quot;Contact_City&quot; SIZE=&quot;25&quot;></p>
<p><em>State/Province</em>
<input type=&quot;TEXT&quot; NAME=&quot;Contact_State&quot; SIZE=&quot;2&quot;></p>


<p><em>Zip/Postal Code</em>
<input type=&quot;TEXT&quot; NAME=&quot;Contact_ZipCode&quot; SIZE=&quot;10&quot; MAXLENGTH=&quot;10&quot;></p>
<p><em>Home Phone</em>
<input type=&quot;TEXT&quot; NAME=&quot;Contact_HomePhone&quot; SIZE=&quot;12&quot; MAXLENGTH=&quot;12&quot;></p>
<p><em>E-mail</em>
<input type=&quot;TEXT&quot; NAME=&quot;Contact_Email&quot; SIZE=&quot;25&quot;></p>
<li>
<p>Enter the date of Purchase :</p>
<p><input type=&quot;TEXT&quot; NAME=&quot;purchaseDate&quot; size=&quot;10&quot; MAXLENGTH=&quot;10&quot;>
</p>
<li>
<p>Location of Purchase</p>
<p><input type=&quot;TEXT&quot; NAME=&quot;purchaseplace&quot; SIZE=&quot;50&quot; MAXLENGTH=&quot;50&quot;><br></P>


<OL></OL>
<input type=submit value=&quot;Add Customer&quot;>
<input type=reset value=&quot;Reset Form&quot;>
<A href=&quot;menu1.htm&quot;> View Reports</A>
<A href=&quot;search1.htm&quot;> Search for Product ID</A>
<A href=&quot;search2.htm&quot;> Search for Keyword</A>
</LI>
</body>
</HTML>
</form>
and the action form named insertdata.cfm
<CFQUERY NAME=&quot;adduser&quot; DATASOURCE=&quot;custsrvc&quot;>
INSERT INTO complaint
(product_id,
issue_summary,
issue_description,
DateofPurchase ,
LocationofPurchase,
custfirstname ,
custlastname ,
custaddress ,
custaddress2 ,
custcity,
custstate,
custzip,
custphone ,
custemail ,
currentdate,
username)
VALUES
('#form.product_model#',
'#form.summary#',
'#form.description#',
'#form.purchasedate#',
'#form.purchaseplace#',
'#form.contact_firstname#',
'#form.contact_lastname#',
'#form.cont_streetaddress#',
'#form.contact_address2#',
'#form.contact_city#',
'#form.contact_state#',
'#form.contact_zipcode#',
'#form.contact_homephone#',
'#form.contact_email#',
'#form.purchasedate#',
'#form.user_name#')
</CFQUERY>
<html>
<head>
<title> Add Customer</title>
</head>
<body>
Record added.
<br><br>
<A href=&quot;customerservice1.cfm&quot;> Back</A>
</br></br>
</body>
</html>

 
Not sure what you are asking. Unless I have completly missed the boat on the intent of your question, there is no output in the insertdata.cfm page because you have not coded anything to output between a <cfoutput>code</cfoutput>

Chris Scott
The Whole Computer Medical Systems
 
<html>
<head>
<title> Add Customer</title>
</head>
<body>
<cfoutput>
Record added.
<br><br>
<A href=&quot;customerservice1.cfm&quot;> Back</A>
</cfoutput>
</br></br>
</body>
</html>

I still get a blank output page, not even the field names.

What else can it be?
 
You need to add something like this to display the fieldnames and values.

<table>
<cfloop index=&quot;i&quot; list=&quot;form.fieldnames&quot; delimiters=&quot;,&quot;>
<cfoutput><tr>
<td>#i#</td><td>#Evaluate(i)#</td>
</tr></cfoutput>
</cfloop>
</table>

Chris Scott
The Whole Computer Medical Systems
 
I get a totally blank output page.
This dosen't even print out.

Plus my database does not get a new record inserted into it.


<html>
<head>
<title> Add Customer</title>
</head>
<body>
<cfoutput>
Record added.
<br><br>
<A href=&quot;customerservice1.cfm&quot;> Back</A>
</br></br>
</body>
</html>
</cfoutput>
 
It looks like you have </form> in the wrong place.

GracefulWebDevelopment.com
 
I even tried to move the end form to this spot

<input type=submit value=&quot;Add Customer&quot;>
<input type=reset value=&quot;Reset Form&quot;>
</form>
<A href=&quot;menu1.htm&quot;> View Reports</A>
<A href=&quot;search1.htm&quot;> Search for Product ID</A>
<A href=&quot;search2.htm&quot;> Search for Keyword</A>
</LI>
</body>
</HTML>

 
Try giving the form a name.

Chris Scott
The Whole Computer Medical Systems
 
I have added <FORM method=&quot;post&quot; action=&quot;insertdata.cfm&quot; name=&quot;add_user&quot;>

Still not working

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top