Professional Documents
Culture Documents
IP Contents of BP
IP Contents of BP
IP Contents of BP
Which of the following programming languages is commonly used for front-end web
development?
a) Java
b) Python
c) HTML
d) PHP
Answer: c) HTML
2. Which term refers to the process of adapting a website's layout to fit different screen sizes and
devices?
a) Responsiveness
b) Browser compatibility
d) Back-end development
Answer: a) Responsiveness
a) jQuery
b) Bootstrap
c) Node.js
d) AngularJS
Answer: b) Bootstrap
5. Which term refers to the process of combining and minifying multiple CSS or JavaScript files
into a single file?
a) Bundling
b) Parsing
c) Debugging
d) Caching
Answer: a) Bundling
6. Which protocol is commonly used to transfer data between a web server and a web browser?
a) HTTP
b) FTP
c) SMTP
d) DNS
Answer: a) HTTP
7. Which term refers to the process of converting a website design into a functioning web page?
a) Wireframing
b) Prototyping
c) Front-end development
d) Back-end development
a) Caching
b) Cookies
c) Sessions
d) Local storage
Answer: b) Cookies
a) WordPress
b) Git
c) Django
d) Ruby on Rails
Answer: a) WordPress
10. Which term refers to the process of analyzing and improving a website's performance,
accessibility, and user experience?
b) Quality assurance
c) Website optimization
d) Database administration
1. Which of the following is a markup language used to structure the content of a web page?
a) HTML
b) CSS
c) JavaScript
d) PHP
Answer: a) HTML
c) Client-Side Scripting
3. Which HTML tag is used to define the main heading of a web page?
a) <body>
b) <header>
c) <h1>
d) <title>
Answer: c) <h1>
a) font-color
b) text-style
c) color
d) text-color
Answer: c) color
5. Which of the following is NOT a valid way to include JavaScript in an HTML file?
a) <script src="script.js"></script>
b) <javascript src="script.js"></javascript>
c) <script>alert("Hello, World!");</script>
d) <a href="script.js"></a>
6. Which CSS property is used to create space between the content and the border of an element?
a) padding
b) margin
c) spacing
d) border-spacing
Answer: a) padding
a) setHTML()
b) changeText()
c) innerHTML()
d) setText()
Answer: c) innerHTML()
a) #
b) .
c) *
d) %
Answer: b) .
a) <ol>
b) <li>
c) <ul>
d) <list>
Answer: c) <ul>
10. Which JavaScript method is used to add an event listener to an HTML element?
a) addEventListener()
b) onClick()
c) listen()
d) attachEvent()
Answer: a) addEventListener()
11. Which CSS property is used to change the font size of text?
a) font-size
b) text-size
c) size
d) font-style
Answer: a) font-size
12. Which HTML tag is used to create a hyperlink?
a) <link>
b) <a>
c) <href>
d) <url>
Answer: b) <a>
13. Which CSS property is used to align text to the center of an element?
a) text-align
b) align-text
c) center-text
d) text-center
Answer: a) text-align
14. Which JavaScript method is used to retrieve the value of an input field?
a) getValue()
b) retrieveValue()
c) getElementValue()
d) value
Answer: d) value
a) <image>
b) <img>
c) <picture>
d) <src>
Answer: b) <img>
a) border
b) border-style
c) border-width
) border-color
Answer: a) border
a) toUpperCase()
b) upperCase()
c) toUpper()
d) upper()
Answer: a) toUpperCase()
a) <row>
b) <tr>
c) <td>
d) <table>
Answer: b) <tr>
19. Which CSS property is used to set the background color of an element?
a) background-color
b) color
c) background
d) bg-color
Answer: a) background-color
20. Which JavaScript method is used to remove an HTML element from the document?
a) removeElement()
b) deleteElement()
c) remove()
d) delete()
Answer: c) remove()
a) <br>
b) <break>
c) <lb>
d) <newline>
Answer: a) <br>
22. Which CSS property is used to set the font style of text?
a) font
b) font-style
c) text-style
d) style
Answer: b) font-style
23. Which JavaScript method is used to round a number to the nearest integer?
a) round()
b) ceil()
c) floor()
d) toInt()
Answer: a) round()
a) <ol>
b) <li>
c) <ul>
d) <list>
Answer: a) <ol>
a) size
b) width
c) element-width
d) setWidth()
Answer: b) width
26. Which JavaScript method is used to convert a string to a number?
a) parseNumber()
b) toNumber()
c) parseInt()
d) number()
Answer: c) parseInt()
a) <h2>
b) <heading2>
c) <h>
d) <level2>
Answer: a) <h2>
a) size
b) height
c) element-height
d) setHeight()
Answer: b) height
29. Which JavaScript method is used to get the current date and time?
a) getCurrentTime()
b) getDate()
c) now()
d) getTime()
Answer: c) now()
a) <input>
b) <form>
c) <field>
d) <textfield>
Answer: a) <input>
1. Which of the following is a server-side scripting language commonly used for web
development?
a) PHP
b) JavaScript
c) HTML
d) CSS
Answer: a) PHP
2. Which database management system is commonly used with PHP for storing and retrieving
data?
a) MySQL
b) MongoDB
c) PostgreSQL
d) Oracle
Answer: a) MySQL
b) mysql_connect()
c) pdo_connect()
d) db_connect()
Answer: a) mysqli_connect()
a) INSERT INTO
b) UPDATE
c) SELECT
d) DELETE FROM
5. Which PHP function is used to execute an SQL query and fetch the results from a MySQL
database?
a) mysqli_query()
b) mysql_query()
c) pdo_query()
d) db_query()
Answer: a) mysqli_query()
6. Which PHP function is used to retrieve a single row of data from a MySQL result set?
a) mysqli_fetch_row()
b) mysql_fetch_row()
c) pdo_fetch_row()
d) db_fetch_row()
Answer: a) mysqli_fetch_row()
7. Which PHP function is used to retrieve multiple rows of data from a MySQL result set?
a) mysqli_fetch_array()
b) mysql_fetch_array()
c) pdo_fetch_array()
d) db_fetch_array()
Answer: a) mysqli_fetch_array()
8. Which PHP function is used to sanitize user input and prevent SQL injection in a MySQL
query?
a) mysqli_real_escape_string()
b) mysql_escape_string()
c) pdo_escape_string()
d) db_escape_string()
Answer: a) mysqli_real_escape_string()
9. Which PHP function is used to handle errors and exceptions in MySQL database operations?
a) mysqli_error()
b) mysql_error()
c) pdo_error()
d) db_error()
Answer: a) mysqli_error()
10. Which PHP superglobal variable is used to retrieve data sent through a POST request?
a) $_POST
b) $_GET
c) $_REQUEST
d) $_SERVER
Answer: a) $_POST
11. Which PHP function is used to redirect the user to a different page?
a) header()
b) redirect()
c) location()
d) navigate()
Answer: a) header()
12. Which MySQL data type is used to store text with a fixed length?
a) CHAR
b) VARCHAR
c) TEXT
d) BLOB
Answer: a) CHAR
13. Which PHP function is used to encrypt passwords for secure storage in a MySQL database?
a) password_hash()
b) md5()
c) sha1()
d) hash()
Answer: a) password_hash()
a) UPDATE
b) INSERT INTO
c) DELETE FROM
d) SELECT
Answer: a) UPDATE
15. Which PHP function is used to retrieve the number of rows affected by a MySQL query?
a) mysqli_affected_rows()
b) mysql_affected_rows()
c) pdo_affected_rows()
d) db_affected_rows()
Answer: a) mysqli_affected_rows()
16. Which MySQL data type is used to store a date and time value?
a) DATE
b) TIME
c) DATETIME
d) TIMESTAMP
Answer: c) DATETIME
17. Which PHP function is used to format a date and time value in a specific format?
a) date()
b) time()
c) format()
d) strftime()
Answer: a) date()
18. Which SQL statement is used to delete data from a MySQL database?
a) DELETE FROM
b) UPDATE
c) INSERT INTO
d) SELECT
19. Which PHP function is used to start a session and store session data?
a) session_start()
b) start_session()
c) initiate_session()
d) begin_session()
Answer: a) session_start()
20. Which MySQL data type is used to store a large amount of binary data?
a) BINARY
b) VARBINARY
c) BLOB
d) TEXT
Answer: c) BLOB
a) isset()
b) empty()
c) session_isset()
d) session_is_set()
Answer: a) isset()
22. Which SQL statement is used to retrieve data from a MySQL database based on specified
conditions?
a) SELECT
b) UPDATE
c) INSERT INTO
d) DELETE FROM
Answer: a) SELECT
a) mysqli_close()
b) mysql_close()
c) pdo_close()
d) db_close()
Answer: a) mysqli_close()
24. Which MySQL data type is used to store a numeric value with decimal precision?
a) INT
b) FLOAT
c) DECIMAL
d) DOUBLE
Answer: c) DECIMAL
25. Which PHP function is used to retrieve the ID of the last inserted record in a MySQL
database?
a) mysqli_insert_id()
b) mysql_insert_id()
c) pdo_last_insert_id()
d) db_last_insert_id()
Answer: a) mysqli_insert_id()
26. Which SQL statement is used to create a new table in a MySQL database?
a) CREATE TABLE
b) ALTER TABLE
c) DROP TABLE
d) INSERT INTO
27. Which PHP function is used to check if a file exists on the server?
a) file_exists()
b) exists()
c) file_check()
d) is_file()
Answer: a) file_exists()
28. Which SQL statement is used to add a new column to an existing table in a MySQL
database?
a) ALTER TABLE
b) CREATE TABLE
c) UPDATE TABLE
d) ADD COLUMN
29. Which PHP function is used to delete a file from the server?
a) unlink()
b) delete_file()
c) remove_file()
d) file_delete()
Answer: a) unlink()
30. Which SQL statement is used to join two or more tables together in a MySQL database
query?
a) JOIN
b) UNION
c) SELECT
d) GROUP BY
Answer: a) JOIN