Advertisement

10.12.2008 at 12:26PM PDT, ID: 23807989
[x]
Attachment Details
[x]
The Solution Rating System

With so many solutions, how can you tell which solutions are most likely to help you and which ones are not? To provide you with a tool to use, we rate our solutions based on various elements that most accurately determine if a solution is a quality solution. To explain what factors affect the solution rating, here are the elements we take into consideration when formulating our solution rating.

  • The Grade of the Solution
  • The Zone Rank of the Expert Providing the Solution
  • The Number of Author and Expert Comments
  • The Number of Experts Contributing
  • The Feedback of the Community

Your Input Matters
Because of the way the system is set up, the most important variable in this equation is you. As a member of Experts Exchange, you are able to cast your vote on the quality of the solutions in regard to how complete, accurate, helpful and easy to understand each solution is. When you provide your feedback, each rating is adjusted accordingly. So, if you see a solution that has a poor rating that you think is a good solution, let us know by rating it. As you do, the rating will be adjusted and will become more accurate for other members of our site.

If you have any suggestions that you would like to make for our rating system, please ask a question in the Suggestions Zone of Community Support.

Thank you!

9.3

Get values on update page after validation fail

Asked by panosms in ColdFusion Application Server, Cold Fusion Markup Language

Tags: ,

Hello experts.
I have one update Page and the problem i have is that after validation fails i want to get on the fields the new values i have entered and not the values from the DB.
I use the extension from Webassist to validate the page.
I'm using form and NOT cfform!
I have tried to use  this code for value:   value="<cfoutput><cfif isDefined("Form.Update.x)>#ItemIndex#<cfelse>#Artikel.Item#</cfif></cfoutput>" but i still getthe query artikel value(artikel.item)
Something else.When i use value="<cfoutput>#ItemIndex#</cfoutput>" i get the values on the page but of  course on the first load i don't get the values of the artikel query.
Any help ?Start Free Trial
1:
2:
3:
4:
5:
6:
7:
8:
9:
10:
11:
12:
13:
14:
15:
16:
17:
18:
19:
20:
21:
22:
23:
24:
25:
26:
27:
<cfif (isDefined("Form.Update.x")) >
.....<!--- here is the validation script --->...
</cfif>
<!--- Now the update query --->
<cfif (isDefined("Form.Update.x")) >
<cfquery name="UpdateArtikel" datasource="#dsn#">
UPDATE ARTIKEL 
SET .......
</cfquery>
 
<!--- Now the query to get the values on the page --->
<cfquery name="artikel" datasource="#dsn#">
SELECT Modell
FROM dbo.artikel
WHERE Art_ID = <cfqueryparam value="#URL.Art_ID#" cfsqltype="cf_sql_numeric"> 
</cfquery>
 
<!---- Here is the code that is specifying  the entered value of the textfield --->
<cfparam name="ItemIndex" default="#ValidatedField("UpdateItem","Item")#" type="string">
 
 
 
 
<form action="Updateitem.cfm?Item_sub_id=<cfoutput>#URLEncodedFormat(artikel.Item_sub_id)#</cfoutput>&Art_ID=<cfoutput>#URLEncodedFormat(artikel.Art_ID)#</cfoutput>" method="post" enctype="multipart/form-data" name="UpdateForm" id="UpdateForm">
<input name="Item" type="text"  id="item" value="<cfoutput>#artikel.item#</cfoutput>" size="18"/>
 <input type="image" name="Update" id="Update" value="Update" alt="Update" src="update.gif" />
 </form>
 
Loading Advertisement...
 
[+][-]10.13.2008 at 08:34AM PDT, ID: 22703307

View this solution now by starting your 14-day free trial. Setting up your free trial is quick, easy, and secure. We will return you to this solution, unlocked, when you're done.

 

About this solution

Zones: ColdFusion Application Server, Cold Fusion Markup Language
Tags: ADOBE, COLDFUSION
Sign Up Now!
Solution Provided By: gdemaria
Participating Experts: 1
Solution Grade: A
 
 
[+][-]10.13.2008 at 09:14AM PDT, ID: 22703650

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 14-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]10.15.2008 at 02:24AM PDT, ID: 22719090

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 14-day free trial to view this Author Comment or ask the Experts your question.

 
 
Loading Advertisement...
20081112-EE-VQP-43 / EE_QW_2_20070628