ChronoEngine.com homepage

Forums

Please write a review for the extension you are using on the Joomla extensions directory before posting a new question as we are being spammed by many negative reviews.

Thank you for your support!

How to multiply field using developer Field Value only

AFROSET 28 Nov, 2018
I greatly need your help on how to twist my js code not to use front end input value but only use Field Value from development area for calculation and deliver the usual way on #total

Twist this as an example for me
$("#field1,#field2").on("change", function(){
  $("#total").val(parseInt($("#field1").val()) + parseInt($("#field2").val()));
});
healyhatman 28 Nov, 2018
Sorry but not sure what it is you mean.
AFROSET 28 Nov, 2018
sorry my tag is chronoform v6.I want to use js calculation code but I need it to only use my own input value field value to run the calculation because that field will be disabled for user at front end.
healyhatman 28 Nov, 2018
So do it then? Use a hidden field. Just DON'T use that front end calculated value in the backend for obvious reasons.
AFROSET 28 Nov, 2018
Healyhatman. I didn't understand you. Can you please share more light on this.
I really need help
healyhatman 28 Nov, 2018
Use a hidden field and calculate using the value of that

Or

Hard code the value

Or

In the js code block use {var:myvalue} and set that var before the page load

whatever you choose, just don't send that calculated value and use it in your form data because the client could very easily change it before sending. Do your final calculation on the server with a PHP block.
This topic is locked and no more replies can be posted.

2Checkout.com

2CheckOut.com Inc. (Ohio, USA) is an authorized retailer for goods and services provided by ChronoEngine.com