Hi I have a webpage that contains multi-languages
I created a JSON file that has a key for each word on the page
but I want to but an empty language ( don't ask me why ) that's like this:
the original word Hi there ==>
so I created a thing like this in JSON
"langCode": " ",
"langName": " ",
"services": " ",
"clients": " ",
"features": " ",
"about": " ",
"contact": " ",
"letsBuildTheWwweb": " ",
"teamOfDevelopersUiuxDesignersAndLogoDesigners": " ",
"hireUs": " ",
"webDeveloping": " ",
"cryptoSystem": " ",
"logoDesinging": " ",
"seoOptimazation": " ",
"webHosting": " ",
"adsOptimazation": " ",
"webDesigning": " ",
"uiUxDesinging": " ",
"ecommerce": " ",
"domainRegistration": " ",
I insert json into HTML this way :
$.getJSON(dir, (lang) => {
document.querySelector('.langCode').innerText = lang.langCode;
});
when I open the page I see everywhere not
Dear moderators, I'm noob in StackOverflow so if I have wrongs in my questions don't delete it cuz I got banned 4 times
innerHTMLinstead ofinnerText