01What does HTTPS add on top of HTTP, and why?
HTTPS layers SSL (Secure Sockets Layer) encryption on top of HTTP, so sensitive data like usernames and passwords aren't sent as readable plain text and can't easily be intercepted by hackers.
02What is a software port, and why are they numbered?
A 16-bit number that, combined with a server's IP address, identifies a specific service running on that server — e.g. port 80 for HTTP, 443 for HTTPS, 21 for FTP — so one machine can offer many services at once.
03How does a browser resolve a domain name to an IP address?
It checks its own cache first, then the operating system's cache, then the local ISP's DNS server; if still not found, the ISP's DNS server runs a recursive search starting from one of the global root servers.
04What's the difference between a static and a dynamic web page?
A static page's content stays the same until someone edits the code manually. A dynamic page runs server-side code on each visit — often querying a database — to build a page tailored to that specific request.
05What's the difference between client-side and server-side scripting?
Client-side scripts (JavaScript, VBScript) run in the browser — fast, but users can disable them. Server-side scripts (PHP, ASP, JSP) run on the server and send back plain HTML, so they can't be blocked but add load to the server.
06Why should form validation usually happen on the client side rather than the server?
Checking on the client gives instant feedback without a round trip across the Internet, and avoids adding unnecessary load and network traffic to an already busy server.
07What are the three ways to implement CSS?
Inline (a style attribute on one tag), embedded (inside the page's HEAD section), and linked (an external .css file referenced by the page) — linked CSS is the most reusable across many pages.
08What is the difference between a container tag and an empty tag?
A container tag needs both an opening and a closing tag, wrapping content between them (e.g. <BODY>...</BODY>). An empty tag has no content to wrap and needs no closing tag (e.g. <BR>, <IMG>).
09What are the four essential tag pairs every HTML document needs?
<HTML>, <HEAD>, <TITLE>, and <BODY> — HTML wraps the whole document, HEAD holds metadata like the title, TITLE sets the browser tab text, and BODY holds the visible page content.
10What's the difference between the <P> and <BR> tags?
<P> starts a new paragraph, with a blank line added before it. <BR> just breaks the current line and continues immediately on the next line, without adding paragraph spacing.
11Why do HTML entities exist?
Characters like < and > are part of HTML's own syntax, so typing them literally would be read as a tag. HTML entities (like < for <) let these reserved characters be displayed as ordinary text.
12What is the purpose of the Alt attribute on the <IMG> tag?
It provides fallback text shown if the image fails to load, and is read aloud by screen readers — making the page accessible even when the image itself isn't available.
13What's the difference between the <B> tag and the <STRONG> tag?
Visually they look the same — both render bold. But <STRONG> is a phrase tag meant to mark text as semantically important, while <B> is purely a stylistic instruction with no added meaning.
14What does a payment gateway do in an online transaction?
It acts as a secure bridge between a merchant's web server and a bank's web server, transferring payment data in encrypted form during an online purchase or money transfer.