Skip to main content

Posts

Showing posts from July, 2020

DOM(document object manipulation)

HTML text:: <!DOCTYPE html> <html lang="en" dir="ltr">   <head>     <meta charset="utf-8">     <title>DOM Manipulation</title>   </head>   <body> <div class="container">   <div class="child">child1</div>   <div class="child">child2</div>   <div class="child">child3</div>   <div class="child">child4</div> </div> <form class="" action="index.html" method="post">   <a href="/"></a>   <input type="text" name="" value="">   <button type="button" name="button">Click</button> </form> <script src="index11.js" charset="utf-8"></script>   </body> </html> JS text:: let a = document; a= document.all; // a=document.body; // a=document.form; ...

Manipulating website with javascript window object

HTML Code:: <!DOCTYPE html> <html lang="en"> <head>     <meta charset="UTF-8">     <meta name="viewport" content="width=device-width, initial-scale=1.0">     <meta http-equiv="X-UA-Compatible" content="ie=edge">     <title> javascript window object</title> </head> <body>      </body> <script src=""></script> </html> JS Code::  let a = window.document; // alert("hello shubh"); // a = prompt("This is End of the World"); // a= confirm("Are you sure to die"); a=window.innerHeight; a=window.innerWidth; a=scrollY; a= location; a=history; console.log(a); NotePad text:: window.alert or alert is equal. Window is a set of object. It also have document part, you can look as a = window.document, prompt provide a box to fill any details and it will save your data whatever you put. confirm object will delete your saved...