Web Technology MCQ (Multiple Choice Questions)

Here are 1000 Web Technology MCQ (Chapterwise).

1. What is web technology?
a) A collection of tools and techniques used to create and deliver content on the World Wide Web
b) A type of software that enables users to access and interact with information on the internet
c) A network of interconnected computers that share information and services
d) A system for storing and retrieving information on the internet
View Answer

Answer: a
Explanation: Web technology is a term that encompasses the tools, techniques, and standards used to create and deliver content on the World Wide Web. This includes markup languages like HTML and CSS, scripting languages like JavaScript, client-side technologies like HTML5 and CSS3, server-side technologies like PHP and Java, databases, networking protocols, and more.

2. Which HTML tag is used to create a hyperlink?
a) <link>
b) <href>
c) <a>
d) <hyperlink>
View Answer

Answer: c
Explanation: The HTML tag <a> is used to create a hyperlink, which is a link to another web page or resource. The <a> tag has two main attributes: href and target. The href attribute specifies the URL of the linked resource, while the target attribute specifies whether the link should open in a new browser window or tab.

3. Which of the following is not a web component element?
a) <shadow>
b) <menu>
c) <content>
d) <element>
View Answer

Answer: b
Explanation: There are web components in HTML related technology which makes it possible to essentially create and use custom elements as if it were regular HTML. You can also create custom versions of standard HTML elements. Some of the elements are <shadow>, <content>, <element>, <template>, <slot>.
advertisement
advertisement

4. Which of the following programming languages is commonly used for server-side scripting in web development?
a) HTML
b) CSS
c) JavaScript
d) PHP
View Answer

Answer: d
Explanation: HTML, CSS, and JavaScript play crucial roles in front-end development, focusing on the visual aspects of web pages, while PHP serves as the primary language for server-side scripting. It manages backend tasks such as database interactions, processing user input, and generating dynamic content.

5. Which of the following is used to read a HTML page and render it?
a) Web server
b) Web matrix
c) Web browser
d) None of the mentioned
View Answer

Answer: c
Explanation: A web browser (commonly referred to as a browser) is a software application for retrieving, presenting and traversing information resources on the World Wide Web.

6. Which of the following is a popular front-end framework for building user interfaces in JavaScript?
a) Django
b) Angular
c) Flask
d) Node.js
View Answer

Answer: b
Explanation: Angular is a widely used front-end framework specifically designed for creating dynamic and interactive user interfaces in JavaScript.

7. What application can one create even before the introduction of HTML5?
a) Forms
b) Browser based games
c) Web applications
d) Mobile applications
View Answer

Answer: a
Explanation: With the help of HTML5 and JavaScript it became possible to create excellent mobile applications, browser based games, web applications and many more other applications. Forms were already introduced before HTML5.
advertisement

8. Which of the following is not associated with web socket communication?
a) https
b) wss
c) http
d) ws
View Answer

Answer: c
Explanation: For opening WebSocket we call WebSocket constructor. The syntax is

var conn=new WebSocket(‘ws://rtyyghj.websocket.org/echo’,[‘brush’, ‘xmpp’]);

for using secure HTTP connections use https: ,ws: is the new URL scheme for connecting WebSockets. There is wss: also.

advertisement

9. Why are Images often used on the webpage?
a) To create graphical buttons or links to other pages
b) To help the webpage load efficiently
c) Webpage cannot run/be displayed without at least one image
d) Because webpage doesn’t support pure text
View Answer

Answer: a
Explanation: Images are also used for better presentation of webpage. Any image can be turned into a link. Rather than putting text between the opening < a > tag and the closing < /a > tag, you simply place an image inside these tags.

10. What is DOM?
a) Application programming interface
b) Hierarchy of objects in ASP.NET
c) Convention for representing and interacting with objects in html documents
d) None of the mentioned
View Answer

Answer: c
Explanation: The Document Object Model (DOM) is a cross-platform and language-independent convention for representing and interacting with objects in HTML, XHTML, and XML documents.

11. What are tables in web programming?
a) Display information which are already accessed by the user
b) Containing more number of rows than columns
c) To only store data to be accessed later by the user
d) Display information in rows and columns used to display all manner of data that fits in a grid
View Answer

Answer: d
Explanation: Tables display information in rows and columns; they are commonly used to display all manner of data that fits in a grid such as train schedules, television listings, financial reports, and sports results.

12. What does <td> stand for?
a) Table database
b) Table data
c) Table directory
d) Table direct row
View Answer

Answer: b
Explanation: While a row is contained inside a < tr > element, each cell is then written inside the row element using a < td > element which stands for table data. If you are looking at a web page and want to know whether that page is using a table to control how the data is laid out, you can always look at the source for that page.

13. Which element to used to give title to a table?
a) Caption
b) Headline
c) Title
d) Heading
View Answer

Answer: a
Explanation: By using a <caption> element, rather than just describing the purpose of the table in a previous or subsequent paragraph, you are directly associating the content of the table with this description- and this association can be used by screen readers and by applications that process web pages (such as search engines).

14. What are Forms in web programming?
a) They are matrices on web page
b) They are used to create Table data and its information
c) They allow you to enter data which can be processed to servers
d) They are the information filled by the server-side
View Answer

Answer: c
Explanation: Forms can look a lot like papers or database forms. A form is filled using text boxes, chechboxes, radiobuttons. For example, applying/order a product from online or it’s a google search result.

15. What are Frames?
a) They divide a webpage
b) They are the type of borders used for a webpage
c) They are the type of borders used by web browsers
d) They divide the browser into two or more pieces or panes
View Answer

Answer: d
Explanation: Browser gets divided into panes by Frame, with each pane containing a separate web page. The advantages are that they offer you where you can load and reload single panes without having to reload the entire contents of the browser window.

16. Which HTML tag is used to create an ordered list in a webpage?
a) <ol>
b) <ul>
c) <li>
d) <ol> and <ul>
View Answer

Answer: a
Explanation: The <ol> tag is used to create an ordered list in a webpage. Ordered lists are lists where the items have a specific order or sequence. The items in an ordered list are typically numbered or lettered.

17. Which font format is used in web pages?
a) EOT
b) WOFF 2.0
c) WOFF
d) SVG Fonts
View Answer

Answer: c
Explanation: WOFF is font format used in web pages. It was developed in 2009. It is essentially OpenType or TrueType with compression and additional metadata. The goal is to support font distribution from the server to client over the network with bandwidth constraints.

18. Which HTML tag is used to create a form?
a) <form>
b) <input>
c) <select>
d) <textarea>
View Answer

Answer: a
Explanation: The HTML tag used to create a form is <form>. It’s used to define an area where users can input and submit data on a webpage. Inside the <form> tag, various input elements like <input>, <select>, and <textarea> are used to collect information from users. When users fill in the form and submit it, the data is sent to a server for processing or storage.

19. Which of the following property is used to control the space between the border and content in a table?
a) border
b) padding
c) margin
d) resize
View Answer

Answer: b
Explanation: The padding property is used to control the space between the border and content in a table.

Example: table{border: 4px solid black;}

20. Which of the following CSS Property controls how an element is positioned?
a) fix
b) set
c) static
d) position
View Answer

Answer: d
Explanation: Controls how an element is positioned. When set to absolute or fixed, the element is removed completely from the normal flow of the document. When set to relative, the element is moved relative to its position in the normal flow, but a space is left where it would normally have been. The default value, static, means the element remains in the normal flow and is not positioned.

21. Which CSS property can be used to set the image as border instead of the border style?
a) border-image-source
b) background-image-source
c) border-image
d) background-image
View Answer

Answer: a
Explanation: The border-image-source property specifies the path to the image to be used as a border (instead of the normal border around an element).

22. Which of the following property defines labels for a list of items?
a) list-style-type
b) list-style-image
c) list-stylelist-style-type
d) none of the mentioned
View Answer

Answer: a
Explanation: Syntax:

list-style-type: disc | circle | square | decimal | decimal-leading-zero

23. Which of the following communicates with server-side CGI scripts through HTML form submissions and can be written without the use of JavaScript?
a) Interactive Web Pages
b) Static Web Pages
c) Conditional Web Pages
d) All web pages
View Answer

Answer: a
Explanation: An interactive web page can dynamically vary its content based on user preferences. Interactive web pages that communicate with server-side CGI scripts through HTML form submissions were the original “web application” and can be written without the use of JavaScript.

24. What is the special feature of modern web applications?
a) Must load the document to manipulate
b) Can alter contents without loading document
c) Can’t be altered at all
d) Remains static
View Answer

Answer: b
Explanation: Modern web applications can dynamically alter their own content without loading a new document.

25. Which of the following is the Web application equivalent to querySelectorAll()?
a) #()
b) &()
c) !()
d) $()
View Answer

Answer: d
Explanation: Web applications based on jQuery use a portable, cross-browser equivalent to querySelectorAll() named $().

26. Which is the storage that allows the caching of web pages and their associated resources?
a) Offline Web Applications
b) Cookies
c) Web Databases
d) FileSystem API
View Answer

Answer: a
Explanation: HTML5 defines an “Offline Web Applications” API that allows the caching of web pages and their associated resources (scripts, CSS files, images, and so on). This is client-side storage for web applications themselves rather than just their data, and it allows web apps to install themselves so that they are available even when there is no connection to the Internet.

27. When does JavaScript code appear inline within an HTML file?
a) Between or Outside the “script” tag
b) Between the header tag
c) Outside the “script” tag
d) Between the “script” tag
View Answer

Answer: d
Explanation: JavaScript code can appear inline within an HTML file between the “script” tags. Javascript can also be included from an external file specified by the src attribute of a “script” tag.

28. What is the purpose of the event handlers in the JavaScript?
a) Adds innerHTML page to the code
b) Allows JavaScript code to alter the behaviour of windows
c) Performs handling of exceptions and occurrences
d) Change the server location
View Answer

Answer: b
Explanation: Event handlers allow JavaScript code to alter the behavior of windows, of documents, and of the elements that make up those documents.

29. What is Vue JS?
a) Scripting Language
b) A framework
c) Programming Language
d) Directives
View Answer

Answer: b
Explanation: Vue.js is an open-source front-end JavaScript framework for building user interfaces and single-page applications.

30. Which of the following bootstrap styles can be used to create a default progress bar?
a) .progress, .progress-bar
b) .link-progress-bar
c) .nav-progress
d) All of the mentioned
View Answer

Answer: a
Explanation: A progress bar can be used to display how far along in a process a user is. Progress bars are available in a variety of styles in Bootstrap. To create a default progress bar, add a .progress class to a <div> element

31. What is the purpose of JavaScript in web development?
a) To define the structure and content of web pages
b) To add interactivity and behavior to web pages
c) To style and format web pages
d) To manage server-side data and databases
View Answer

Answer: b
Explanation: JavaScript is a scripting language that adds interactivity and behavior to web pages. It makes web pages more dynamic, responsive, and engaging by handling user input, updating content dynamically, creating animations, and communicating with servers.

32. React.js is written in which of the following language?
a) C++
b) C
c) Java
d) JavaScript
View Answer

Answer: d
Explanation: React Native is built on a JavaScript based React.js framework. This is a significant benefit, given that JavaScript is such a widely used language.

33. Which of the following directives is used to start an angularJS application?
a) ng-app
b) ng-init
c) ng-repeat
d) ng-model
View Answer

Answer: a
Explanation: Dependencies are injected in Angular.JS by using an “injectable factory method” or “constructor function.” As dependencies, these components can be injected with “service” and “value” components.

34. How many classes does bootstrap grid system has?
a) 2
b) 3
c) 4
d) 1
View Answer

Answer: c
Explanation: Bootstrap grid system has four classes. Xs, sm, md, lg. as is for phones having screens less than 786px wide, sm is for tablets. Screens equal to or greater than 768px, md is for small laptops, screen equal to or greater than 992px wide, lg is for laptops and desktops, Screens equal to or greater than 1200px wide.

35. What is the JavaScript keyword used to define a function?
a) var
b) function
c) let
d) const
View Answer

Answer: b
Explanation: The function keyword is used to define a function in JavaScript. Functions are blocks of code that can be used to perform actions. They can take input parameters and return a value.

36. Which CSS property is used to specify the width of an element?
a) padding
b) margin
c) height
d) width
View Answer

Answer: d
Explanation: The width CSS property is used to specify the horizontal width of an element. It is a dimension property, which means that it can be specified in different units, such as pixels, ems, or percentages.


Chapterwise Multiple Choice Questions on Web Technology

Web Technology MCQ - Multiple Choice Questions and Answers

Our 1000+ MCQs focus on all topics of the Web Technology subject, covering 100+ topics. This Web Technology MCQ will help you to prepare for exams, contests, online tests, quizzes, viva-voce, interviews, and certifications. You can practice these MCQs chapter by chapter starting from the 1st chapter or you can jump to any chapter of your choice.
  1. Links and Navigation
  2. Images, Audio and Video
  3. Tables
  4. Forms
  5. Frames
  6. HTML
  7. Cascading Style Sheets
  8. JavaScript
  9. Server-side Scripting Languages
  10. Web Development Frameworks

1. Web Technology MCQ on Links and Navigation

The section contains multiple choice questions and answers on understanding URLs and creating hyperlinks with the <a> element.

  • Basic Links
  • Understanding URLs
  • Creating Links with <a> Element
  • 2. Multiple Choice Questions on Images, Audio and Video

    The section contains questions and answers on adding images using the <img> element and choosing the right format, image maps, and adding flash, video, and audio to web pages.

  • Adding Images using the IMG Element
  • Image Maps
  • Choosing the Right Image Format
  • Adding Flash, Video and Audio to Web Page-1
  • Adding Flash, Video and Audio to Web Page-2
  • 3. Web Technology MCQ on Tables

    The section contains web technology MCQs on tables, table elements and attributes, and the grouping section of a table.

  • Tables
  • Table Elements and Attributes
  • Grouping Section of a Table
  • 4. Web Technology MCQ on Forms

    The section contains multiple choice questions and answers on creating forms with form elements, form controls, form accessibility and structure.

  • Forms
  • Creating a Form with the <form> Element
  • Form Controls
  • Form Accessibility and Structure
  • 5. Web Technology MCQ on Frames

    The section contains questions and answers on frames.

  • Frames
  • 6. Web Technology MCQ on HTML

    The section contains multiple choice questions (MCQs) on covering HTML5 concepts, including basics, themes, tables, web storage, web databases, web performance optimization, HTML5 semantics, and advanced HTML concepts.

  • HTML5 Basics
  • Major HTML5 Themes
  • HTML Tables
  • Choosing Web Servers
  • HTML5 Application Elements & Attributes
  • Web Storage
  • Web Databases
  • Web Performance Optimization
  • HTML5 Semantics
  • Responsive Overview – 1
  • Responsive Overview – 2
  • 1000 HTML MCQ
  • 7. MCQ on Cascading Style Sheets

    The section contains multiple choice questions and answers on CSS basics, CSS styling texts, CSS selectors, CSS box model, CSS backgrounds and borders, CSS outline, CSS tables, embedding web fonts, CSS layout, and CSS3 animation.

  • CSS Basics
  • CSS Styling Texts
  • CSS Selectors
  • CSS Box Model
  • CSS Backgrounds and Borders
  • CSS Styling Lists
  • CSS Outline
  • CSS Styling Tables
  • Positioning and Layout with Css
  • Embedding Web Fonts
  • CSS3 Animation with Responsive Web Design
  • 1000 CSS MCQ
  • 8. MCQ on JavaScript

    The section contains questions and answers on JavaScript lexical structure, classes, client-side databases, the jQuery library, web sockets in JavaScript, JavaScript web workers, and modules.

  • JavaScript Lexical Structure
  • JavaScript Classes
  • JavaScript in Web Browsers
  • JavaScript Client-Side Databases
  • jQuery Library
  • Web Sockets in JavaScript
  • JavaScript Web Workers
  • Server-Side JavaScript
  • JavaScript Modules
  • 1000 JavaScript MCQ
  • 9. MCQ on Server-side Scripting Languages

    The section contains multiple choice questions (MCQs) on scripting languages like PHP, Python, Ruby, and Java.

  • 1000 PHP MCQ
  • 1000 Python MCQ
  • 1000 Ruby MCQ
  • 1000 Java MCQ
  • 10. MCQ on Web Development Frameworks

    The section contains multiple choice questions on frameworks like Vue JS, Bootstrap, React JS and Angular JS.

  • Vue JS
  • Bootstrap
  • React JS
  • Angular JS
  • If you would like to learn "Web Technology" thoroughly, you should attempt to work on the complete set of 1000+ MCQs - multiple choice questions and answers mentioned above. It will immensely help anyone trying to crack an exam or an interview.

    Wish you the best in your endeavor to learn and master Web Technology!

    If you find a mistake in question / option / answer, kindly take a screenshot and email to [email protected]

    advertisement
    advertisement
    Subscribe to our Newsletters (Subject-wise). Participate in the Sanfoundry Certification contest to get free Certificate of Merit. Join our social networks below and stay updated with latest contests, videos, internships and jobs!

    Youtube | Telegram | LinkedIn | Instagram | Facebook | Twitter | Pinterest
    Manish Bhojasia - Founder & CTO at Sanfoundry
    Manish Bhojasia, a technology veteran with 20+ years @ Cisco & Wipro, is Founder and CTO at Sanfoundry. He lives in Bangalore, and focuses on development of Linux Kernel, SAN Technologies, Advanced C, Data Structures & Alogrithms. Stay connected with him at LinkedIn.

    Subscribe to his free Masterclasses at Youtube & discussions at Telegram SanfoundryClasses.