Answer the question
In order to leave comments, you need to log in
Access only to a subfolder (htaccess)?
Can't set up .htaccess file
How can I make it so that there is no access to the parent web/ folder , except for the subfolder (or several such subfolders) web/access ?
Answer the question
In order to leave comments, you need to log in
var sss= document.querySelector(".block");
if (sss!== null) {
ваш код
}
Try like this
window.onload = function() {
document.querySelector('.block').addEventListener('click', event => {
console.log(event);
if (event.target.className == 'item'){
var dataTab = event.target.getAttribute('data-tab');
var tabH = document.getElementsByClassName('items');
for (var i=0; i < tabH.length; i++){
tabH[i].classList.remove('active');
}
event.target.classList.add('active');
var tabBody = document.getElementsByClassName('content');
for (var i=0; i < tabBody.length; i++) {
if (dataTab == i) {
tabBody[i].style.display = 'block';
}
}
}
}
}
})
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question