Struggling to find a solution on my own.
In my hidden field, I have some JSON data stored.
To retrieve this data, I'm using the following syntax:
$(document).ready(function() {
var data = $("#result").text();
var j = JSON.parse(data);
j.my_item.total_price==="2222";
console.log(j.my_item.total_price);
});
Although the variable 'j' displays the correct information, I'm unsure how to update the total_price value.
Any suggestions on how to go about updating the total_price?