Untitled Flashcards Set

Q: What is the basic HTML page structure? | A: <!DOCTYPE html><html><head><title>Page</title></head><body>Content</body></html>

Q: How to make a bulleted list? | A: <ul><li>Item 1</li><li>Item 2</li></ul>

Q: How to link CSS to HTML? | A: <link rel="stylesheet" href="style.css">

Q: What tag makes text bold? | A: <b>Text</b>

Q: How to create an email link? | A: <a href="mailto:name@email.com">Email</a>

Q: How to set text color to red in CSS? | A: p { color: red; }

Q: HTML tag for embedding video? | A: <video src="video.mp4" controls></video>

Q: Create a form with a text box and submit button | A: <form><input type="text"><input type="submit"></form>

Q: Declare a JavaScript variable? | A: let x = 5;

Q: Show an alert popup? | A: alert("Hello!");

Q: What is the DOM? | A: Document Object Model = webpage structure.

Q: Change text in HTML element with id "demo"? | A: document.getElementById("demo").innerHTML = "New Text";

Q: Hide an element with jQuery? | A: $("#id").hide();

Q: What is JSON? | A: { "name": "John" } (data format)

Q: Comment in JavaScript? | A: // This is a comment

Q: JSON vs XML? | A: JSON uses {key:value}, XML uses <tags>.the