PHP Quiz

PHP Quiz

University

15 Qs

quiz-placeholder

Similar activities

QUIZ 2 - WEB PROGRAMMING CSC443

QUIZ 2 - WEB PROGRAMMING CSC443

University

10 Qs

Programación Web

Programación Web

1st Grade - University

10 Qs

Kelas PHP

Kelas PHP

University

20 Qs

SKEE1103 CT#11c: Pointers and Functions

SKEE1103 CT#11c: Pointers and Functions

University

11 Qs

C Quiz

C Quiz

University

15 Qs

POST TEST MODULE 4

POST TEST MODULE 4

University

10 Qs

Java set3

Java set3

University

10 Qs

Pemrograman Web 02

Pemrograman Web 02

University

14 Qs

PHP Quiz

PHP Quiz

Assessment

Quiz

Other

University

Hard

Created by

Frances Lumanglas

Used 1+ times

FREE Resource

15 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

You want to collect user information through a form and display it in the URL. Which method should you use?

Post

Get

Put

Request

2.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

You are creating a function to calculate the total cost of items in a shopping cart. Which variable scope should you use to keep track of the total cost within the function only?

Parameter

Static

Local

Static

3.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

You are tasked with creating an array to store information about employees, including their names and ages. Which type of array in PHP would be MOST appropriate for this situation?

Associated Array

Multidimensional Array

Sequential Array

Indexed Array

4.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

You are working on a project where a variable needs to retain its value between function calls. What keyword should you use during variable declaration?

Volatile

Persist

Retain

Static

5.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

You want to loop through an array and perform a specific action for each element. Which loop is MOST suitable for this task?

For-loop

Do-while-loop

While loop

For each loop

6.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

In a script, you have a variable named $discount that should be accessible from any part of the code, including functions. What should you use to achieve this?

Local Scope

Static Scope

Global Scope

Parameter Scope

7.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which of the following is the CORRECT way of creating a hyperlink in HTML?

<a>www.geeksforgeeks.org <Geeksforgeeks /a>

<a href= “www.geeksforgeeks.org”>Geeksforgeeks</a>

<a link=“www.geeksforgeeks.org” Geeksforgeeks> </a>

<a href=“www.geeksforgeeks.org” Geeksforgeeks /a>

Create a free account and access millions of resources

Create resources
Host any resource
Get auto-graded reports
or continue with
Microsoft
Apple
Others
By signing up, you agree to our Terms of Service & Privacy Policy
Already have an account?