• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Javascript Calculation Rendered value

 
Scott Minor
Greenhorn
Posts: 5
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

I have a field in a JSF form that is bound to a database field that is really a calculated value, depending what the user enters into the value field the calculated values needs to change and be stored. I have written a java script function that does the calculation and updates the screen, but when I try to save the value with the submit button I get the old value for the calculated field. Not sure why this is happening.

Any help is appreciated.
 
Himanshu Kansal
Ranch Hand
Posts: 257
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Does the updated value reflect in the textfield? Try to alert out the value of this textfield when you click submit and see what you get.
 
Scott Minor
Greenhorn
Posts: 5
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Yes the value is updated in the textfield by when I save the data to the database it doesn't show the new value. Its still the old one.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic