javascript foreach
const avengers = ['thor', 'captain america', 'hulk'];
avengers.forEach((item, index)=>{
console.log(index, item)
})
javascript foreach
const avengers = ['thor', 'captain america', 'hulk'];
avengers.forEach((item, index)=>{
console.log(index, item)
})
javascript foreach
var colors = ['red', 'blue', 'green'];
colors.forEach(function(color) {
console.log(color);
});
javascript foreach example
var colors = ["red", "blue", "green"];
colors.forEach(function(color) {
console.log(color);
});
foreach loop javascript
const numList = [1, 2, 3];
numList.forEach((number) => {
console.log(number);
});
javascript foreach
let numbers = ['one', 'two', 'three', 'four'];
numbers.forEach((num) => {
console.log(num);
}); // one //two //three // four
foreach js
// result.params.detail = {
// "status": true,
// "message": "",
// "params": {
// "pay_credit_remain": 115,
// "month_expiry": "15",
// "detail": [
// {
// "credit": "70",
// "create_date": "2020-10-16",
// "expiry_date": "2022-01-16"
// },
// {
// "credit": "45",
// "create_date": "2020-10-17",
// "expiry_date": "2022-01-17"
// }
// ]
// }
//}
detail = "<ul>";
result.params.detail.forEach((val) => {
detail = detail + sprintf(lang.pay_credit_detail, val.credit, val.expiry_date);
});
detail += "</ul>";
$('#pay_credit_remain').html(detail);
Copyright © 2021 Codeinu
Forgot your account's password or having trouble logging into your Account? Don't worry, we'll help you to get back your account. Enter your email address and we'll send you a recovery link to reset your password. If you are experiencing problems resetting your password contact us