Search
 
SCRIPT & CODE EXAMPLE
 

JAVASCRIPT

how to make a div appear when clicked on in javascript

function showDiv() {
  document.getElementById('sign-in').style.display = "block";
}
Comment

how to make a div appear when clicked on in javascript

<a class="btn btn-default log-bar" href="#" role="button" onclick="showDiv()">Login</a>


<div id="sign-in" class="login" style="display: none;">
  <form>
    <div class="row">
      <div class="col-md-3">
        <div class="form-group inline-form">
          <input type="email" class="form-control" id="email" Placeholder="email">
        </div>
      </div>
      <div class="col-md-3">
        <div class="form-group inline-form">
          <input type="password" class="form-control" id="pwd">
        </div>
      </div>
      <div class="col-md-3">
        <div class="checkbox">
          <label><input type="checkbox"> Remember me</label>
        </div>
      </div>
      <div class="col-md-3">
        <button type="submit" class="btn btn-default ">Submit</button>
      </div>
    </div>
  </form>
</div>
Comment

PREVIOUS NEXT
Code Example
Javascript :: regex to find emails 
Javascript :: fabric download 
Javascript :: reactjs cut part of string 
Javascript :: how to show progress on ajax call 
Javascript :: how to get file type in javascript 
Javascript :: preloader 
Javascript :: nvm check version available to download 
Javascript :: scroll to top router link vue 
Javascript :: tribonacci sequence javascript 
Javascript :: js array includes 
Javascript :: javascript loop object 
Javascript :: javascript wait for element 
Javascript :: != vs !== javascript 
Javascript :: vue router refresh page not found 
Javascript :: how to filter list of objects by an array in javascript 
Javascript :: tsconfig 
Javascript :: how to assert element attributes in cypress 
Javascript :: javasript document referrer 
Javascript :: vscode 
Javascript :: javascript create array with repeated values 
Javascript :: network display react native 
Javascript :: object.entries 
Javascript :: javascript datetime format 
Javascript :: javascript redirect with extra url arguments 
Javascript :: Iteration over JS object 
Javascript :: how to code print in javascript 
Javascript :: javascript compare two arrays of objects 
Javascript :: how to delete duplicate elements in an array in javascript 
Javascript :: recursion in javascript 
Javascript :: javascript classes and how to import them 
ADD CONTENT
Topic
Content
Source link
Name
1+4 =