Showing posts with label HTML. Show all posts
Showing posts with label HTML. Show all posts

Wednesday, August 28, 2019

Demonstration of fadeIn Method of jQuery

Demonstration of fadeIn Method of jQuery

ANIMATION

Code

<!DOCTYPE html>
<html>
<head>
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.4.1/jquery.min.js"></script>
<script>
$(document).ready(function(){
  $("button").mouseenter(function(){
    $("#div1").fadeIn();
    $("#div2").fadeIn("slow");
    $("#div3").fadeIn(1000);
    $("#div4").fadeIn(2000);
    $("#div5").fadeIn(3000);
  });
 
  $("button").mouseleave(function(){
    $("#div1").fadeOut();
    $("#div2").fadeOut("slow");
    $("#div3").fadeOut(1000);
    $("#div4").fadeIn(2000);

    $("#div5").fadeIn(3000);
  });

});
</script>
<style>
body{
margin: 50px;
}
#button1{
  background-color: #f44336;;
  border: none;
  color: white;
  padding: 15px 32px;
  text-align: center;
  text-decoration: none;
  display: inline-block;
  font-size: 16px;
  margin: 4px 2px;
  cursor: pointer;
}

</style>
</head>
<body>

<h1>Demonstrate fadeIn() with different parameters.</h1>

<button id="button1">Hover the mouse to fade in boxes (move mouse over me and then move out )</button><br><br>


<div id="div1" style="width:90px;height:90px;display:none;background-color:#DD4132;">
</div><br>
<div id="div2" style="width:90px;height:90px;display:none;background-color:#79C753;">
</div><br>
<div id="div3" style="width:90px;height:90px;display:none;background-color:#FA9A85;">
</div><br>
<div id="div4" style="width:90px;height:90px;display:none;background-color:#F96714;">
</div><br>
<div id="div5" style="width:90px;height:90px;display:none;background-color:#FAE03C;">
</div>


</body>
</html>


Tuesday, July 16, 2019

HTML Basic Questions


  Which HTML element defines the title of a document?
  • a)     <head>
  • b)     <title>    Correct answer  
  • c)     <meta>


Answer b)
Question 25:
Which HTML attribute specifies an alternate text for an image, if the image cannot be displayed?
  • a)     longdesc
  • b)     alt    Correct answer  
  • c)     src
  • d)     title


Answer b)
Question 26:
  • Which doctype is correct for HTML5?
  • a)     <!DOCTYPE HTML5>
  • b)     <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 5.0//EN" "http://www.w3.org/TR/html5/strict.dtd">
  • c)     <!DOCTYPE html>    Correct answer  


Answer c)
Question 27:
Which HTML element is used to specify a footer for a document or section?
  1. a)     <section>
  2. b)     <bottom>
  3. c)     <footer>    Correct answer  


Answer c)
Question 28:
In HTML, you can embed SVG elements directly into an HTML page.
a)     True    
b)     False

Answer: a)
Question 29:
What is the correct HTML element for playing video files?
  • a)     <media>
  • b)     <movie>
  • c)     <video>    

Answer c)
Question 30:
What is the correct HTML element for playing audio files?
  • a)     <mp3>
  • b)     <sound>
  • c)     <audio>    


Answer c)
Question 31:
The HTML global attribute, "contenteditable" is used to:
  • a)     Specify whether the content of an element should be editable or not    
  • b)     Specifies a context menu for an element. The menu appears when a user right-clicks on the element
  • c)     Return the position of the first found occurrence of content inside a string
  • d)     Update content from the server



Answer a)

Question 32:
In HTML, onblur and onfocus are:
  • a)     Event attributes    
  • b)     HTML elements
  • c)     Style attributes


Answer a)
Question 33:
Graphics defined by SVG is in which format?
  • a)     CSS
  • b)     HTML
  • c)     XML    


Answer c)
Question 34:
The HTML <canvas> element is used to:
  • a)     create draggable elements
  • b)     manipulate data in MySQL
  • c)     display database records
  • d)     draw graphics    


Answer d)
Question 35:
In HTML, which attribute is used to specify that an input field must be filled out?
  • a)     validate
  • b)     required    
  • c)     formvalidate
  • d)     placeholder


Answer b)
Question 36:
Which input type defines a slider control?
  • a)     search
  • b)     controls
  • c)     range    
  • d)     slider


Answer c)
Question 37:
Which HTML element is used to display a scalar measurement within a range?
  • a)     <meter>    
  • b)     <range>
  • c)     <gauge>
  • d)     <measure>


Answer a)

Question 38:
Which HTML element defines navigation links?
  • a)     <nav>    
  • b)     <navigate>
  • c)     <navigation>


Answer a)
Question 39:
  • In HTML, what does the <aside> element define?
  • a)     Content aside from the page content    
  • b)     The ASCII character-set; to send information between computers on the Internet
  • c)     A navigation list to be shown at the left side of the page


Answer a)
Question 40:
Which HTML element is used to specify a header for a document or section?
  • a)     <head>    
  • b)     <section>
  • c)     <top>
  • d)     <header>    Correct answer

Answer d


Create a Digital Clock using HTML and JavaScript

Create a Digital Clock using HTML and JavaScript  <! DOCTYPE html> < html > < head > ...

Followers

Search This Blog

Popular Posts