how to calculate label values in an array
Hi lllya,
I dont know how ton fix the error or to add a condition.
Catch up wih the Appery.io community on our forum. Here you'll find information on the lastest questions and issues Appery.io developers are discussing.
https://forum.appery.io/
Hi lllya,
I dont know how ton fix the error or to add a condition.
Hi Maryna,
can you help here, i'm getting nowhere,
the error lllya mentions I dont know how to fix
thx
Hi Michael! Sure, we're working on your request. I'll update when have more information.
Hi Michael,
Please try the following construction:preif($this.attr("idx").slice(1))){
...
var index = parseInt($this.attr("idx").slice(1));
....
}/pre
Hi Katya,
unsure if this is the code I need to alter, if it is do I add to the code or replace some of it with your code
codevar mainorderArray;
try {
mainorderArray = JSON.parse(localStorage.getItem("mainorderArray"));
if ({}.toString.call(mainorderArray) !== "[object Array]") {
mainorderArray = [];
Code: Select all
} } catch ( e ) {
mainorderArray = [];
}
var $this = $(this);
var index = parseInt($this.attr("_idx").slice(1));
if (index >=0 && index < mainorderArray.length) {
mainorderArray.splice(index, 1);
}
localStorage.setItem("mainorderArray", JSON.stringify(mainorderArray));
/code
Hi Michael,
There is an extra brace in 'checkout.js', line 271.
What about the code you suggested I try?
Hi Maryna,
can you explain what Katya meant
"extra brace in 'checkout.js', line 271"
I dont see a brace on line 271
and the question above about the code above that
thx
Hello! On checkout page there are 2 errors:
1) STARRUSERREAD - Success - 3. Run JavaScript in line 39 there is a bracket ")", check before this line prelocalStorage.setItem("totalprice", totalprice);/pre so there shouldn't be this bracket.
2) STARRUSERREAD-Complete- 2.Run JavaScript - there is a code preMath.round(totalprice).toFixed(2)/pre it's not correct code because variable totalprice is not defined in this function. Furthermore this code doesn't make sense because you don't use value you get. You can delete this code.