Giter VIP home page Giter VIP logo

combining-html-and-javascript-plus-dom's Introduction

Combining HTML and JavaScript + DOM Lab

Question One

a. Make a website that prompts the user for a string. Then show a popup that displays the string.

b. Instead of showing a popup, make the text appear on the screen.

Question Two

a. Make a website that prompts the user for a number, then alerts them of whether or not the number is even.

b. Instead of showing a popup, make the text appear on the screen.

Question Three

a. Make a website with an input field and a button. Have a heading at the top that reads "Double your number below" When the user clicks on the button, display an alert showing that number times two.

b. Instead of showing a popup, make the doubled number appear in a paragraph below.

c. Make the doubled number instead appear inside the input

Question Four

a. Make a website with a heading at the top that reads "Palindrome detector". Add an input field and a button. When the user clicks the button, display an alert that says whether or not the text in the input field is a palindrome (the same backwards and forwards).

b. Instead of showing a popup, have that information appear in a paragraph below the button.

Question Five

a. Make a website with a heading at the top that reads "String Uppercaser". Add an input field and a button. When the user clicks the button, display an alert that contains the uppercased text of the input text field.

b. Instead of showing a popup, have that information appear in a paragraph below the button.

c. Have the uppercased overwrite the text that was there before.

Question Six

a. Make a website with a heading at the top that reads "String Capital Counter". Add an input field and a button. When the user clicks the button, display an alert that contains a count of how many capital letters are in the string.

b. Instead of showing a popup, have that information appear in a paragraph below the button.

Question Seven

a. Make a website with a heading at the top that reads "String Capital Counter Comparer". Add 2 input fields and a button. When the user clicks the button, display an alert that shows which string has more capital letters in it.

b. Instead of showing a popup, have that information appear in a paragraph below the button.

Question Eight

a. Make a website with a heading at the top that reads "Average of Three Numbers". Add 3 input fields and a button. When the user clicks the button, display an alert that shows the average of all 3 text fields.

b. Instead of showing a popup, have that information appear in a paragraph below the button.

c. If any of the text fields doesn't have a number, show an error message that reads "All of the inputs must be numbers"

Question Nine

a. Make a website with a heading at the top that reads "Check Middle Number Sum". Add 3 input fields and a button. When the user clicks the button, display an alert that shows whether the number in the middle input field is equal to the sum of the left input field and the right input field.

Sample input: 4, 14, 10
Sample output: true

Sample input: 4,9,8
Sample output: false

b. Instead of showing a popup, have that information appear in a paragraph below the button.

Question Ten

a. Make a website with a heading at the top that reads "Disemvoweler". Add 1 input field, a checkbox and a button. When the user clicks the button, display an alert that shows the text in the input field with the vowels removed. If the checkbox is checked, count y as a vowel.

b. Instead of showing a popup, have that information appear in a paragraph below the button.

combining-html-and-javascript-plus-dom's People

Contributors

alejo4373 avatar benstone1 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.