K
K
kot25662020-02-04 12:49:40
JavaScript
kot2566, 2020-02-04 12:49:40

Access only to a subfolder (htaccess)?

Can't set up .htaccess file
5e393d543357b488005189.png
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

2 answer(s)
A
Ankhena, 2019-05-17
@tosster22

var sss= document.querySelector(".block");
if (sss!== null) {
ваш код
}

S
Shohruh Shaimardonov, 2019-05-17
@joeberetta

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 question

Ask a Question

731 491 924 answers to any question