W3Schools PHP

अब Quizwiz के साथ अपने होमवर्क और परीक्षाओं को एस करें!

All variables in PHP start with which symbol? $ ! &

$

How do you get information from a form that is submitted using the "get" method? Request.Form; Request.QueryString; $_GET[];

$_GET[];

Which superglobal variable holds information about headers, paths, and script locations? $_GLOBALS $_SESSION $_SERVER $_GET

$_SERVER

How do you create an array in PHP? $cars = array["Volvo", "BMW", "Toyota"]; $cars = "Volvo", "BMW", "Toyota"; $cars = array("Volvo", "BMW", "Toyota");

$cars = array("Volvo", "BMW", "Toyota");

What is the correct way to add 1 to the $count variable? count++; $count =+1 $count++; ++count

$count++;

Which one of these variables has an illegal name? $my_Var $myVar $my-Var

$my-Var

What is a correct way to add a comment in PHP? <comment>...</comment> <!--...--> /*...*/ *\...\*

/*...*/

What is the correct way to end a PHP statement? . </php> New line ;

;

PHP server scripts are surrounded by delimiters, which? <script>...</script> <?php...?> <&>...</&> <?php>...</?>

<?php ?>

What is the correct way to include the file "time.inc" ? <?php include file="time.inc"; ?> <!-- include file="time.inc" --> <?php include "time.inc"; ?> <?php include:"time.inc"; ?>

<?php include "time.inc"; ?>

Which operator is used to check if two values are equal and of same data type? != === = ==

===

In PHP, the only way to output text is with echo. True False

False

Include files must have the file extension ".inc" True False

False

When using the POST method, variables are displayed in the URL: True False

False

What does PHP stand for? Private Home Page PHP: Hypertext Preprocessor Personal Hypertext Processor

PHP: Hypertext Preprocessor

The PHP syntax is most similar to: VBScript Perl and C JavaScript

Perl and C

In PHP you can use both single quotes ( ' ' ) and double quotes ( " " ) for strings: True False

True

PHP allows you to send emails directly from a script True False

True

PHP can be run on Microsoft Windows IIS(Internet Information Server): True False

True

The die() and exit() functions do the exact same thing. True False

True

The if statement is used to execute some code only if a specified condition is true True False

True

The setcookie() function must appear BEFORE the <html> tag. True False

True

How do you write "Hello World" in PHP "Hello World"; echo "Hello World"; Document.Write("Hello World");

echo "Hello World";

What is the correct way to open the file "time.txt" as readable? open("time.txt"); open("time.txt","read"); fopen("time.txt","r"); fopen("time.txt","r+");

fopen("time.txt","r");

What is the correct way to create a function in PHP? new_function myFunction() function myFunction() create myFunction()

function myFunction()


संबंधित स्टडी सेट्स

IF1 - Chapter 4 - Insurable Interest

View Set

Exam 1 Chapters 6,10,11,12 NRS230

View Set

Module 6: Black Music in the 1960's and Rock

View Set

Prep U unit THREE {Test 2/14/2020}

View Set

CH 31 Drugs for Nasal Congestion and Cough (E2)

View Set

MAN4720 Ch 6 Practice Questions & Quiz

View Set

Adjectives with the same meaning

View Set