Posts

Showing posts from April, 2023

How to create Login form using HTML?

Image
Login is mandatory for any websites nowadays. Here, a login form is designed to get the input from the user. The user has to enter the login id and password.   Html program to create a login form: Simply open an editor like notepad. create a new file and save it as "loginform.html". Type the below coding. <!DOCTYPE html>    <html>    <head>   <meta name=” Description" content="HTML programs"> < meta  name ="viewport"  content ="width=device-width, initial-scale=1.0" > <title> It’s Login page </title>   <style>    <!-- This block defines the style properties  --> Body {   <!-- This defines the font family and sets the background as cyan -->   font-family: Times New Roman, Arial, sans-serif;     background-color: cyan;   }   <!-- This block defines the properties for the button --> button {     ...

Java script – conditional statement

Java script has many conditional statements. It is used to check whether the given condition is true or false. It has following type. ·        If ·        If else ·        If else if Each one is explained as follows. 1.     If statement: This is a simple condition checking statement. It has a syntax to follow. Syntax: If (condition) { Code…. }   Example:   if( a>10)    {           document.writeln(“The number is greater than 10”);    } This example checks the given number is greater than 10. If the condition is true,it prints the number is greater than 10. Next, a simple example which checks the given number is greater than 10 or not is shown below. 2.     if   else: This type of conditional statement is used to check the condition. if the condition is tru...