Correct Answer : Rasmus Lerdorf
Correct Answer : 1995
Correct Answer : Hypertext Preprocessor
Correct Answer : .php
Correct Answer : All of the above
Correct Answer : <?php...?>
Correct Answer : Windows Apache MySQL PHP
Correct Answer : ;
Correct Answer : /*...*/
Correct Answer : echo "Hello World";
Correct Answer : % a
Correct Answer : $
Correct Answer : Perl and C
Correct Answer : <?php include "header.inc"; ?>
Correct Answer : Are different how they handle failure
Correct Answer : GD Library
Correct Answer : include()
Correct Answer : header()
Correct Answer : Multitype variables
Correct Answer : is_numeric()
Correct Answer : $value1= $value?
Correct Answer : ctype_alnum()
Correct Answer : empty()
Correct Answer : Hidden variables
Correct Answer : function myFunction()
Correct Answer : PHP 5
Correct Answer : fopen("footer.txt","r");
Correct Answer : glob()
Correct Answer : bitwise or
Correct Answer : Using strcmp()
$var = 1 / 2;​
Correct Answer : 0.5
<?php $str = 'a\\b\n'; echo $str; ?>​
Correct Answer : a\b\n
Correct Answer : strlen($variable)
Correct Answer : $_POST[];
Correct Answer : $_SERVER[‘HTTP_USER_AGENT’];
Correct Answer : $_PHP_SELF
Correct Answer : $_SERVER
Correct Answer : Doubles
Correct Answer : Get
Correct Answer : $count++;
Correct Answer : $my-Var
<?php $var = 'a'; $VAR = 'b'; echo "$var$VAR"; ?>​
Correct Answer : ab
Correct Answer : Both
Correct Answer : __construct
Correct Answer : $cars = array("Volvo", "BMW", "Toyota");
$a = array( 'a', 3 => 'b', 1 => 'c', 'd' );​
Correct Answer : $a[4]
<?php $a = array( null => 'a', true => 'b', false => 'c', 0 => 'd', 1 => 'e', '' => 'f' ); echo count($a), "\n"; ?>​
Correct Answer : 3
<?php define("Hi","Hello! How are you ?"); echo constant("Hi"); ?>​
Correct Answer : Hello! How are you ?
Correct Answer : array_push()
Correct Answer : $_GET & $_SET
Correct Answer : session_start()
Correct Answer : isset() function
Correct Answer : setcookie()
Correct Answer : session_pw
Correct Answer : Store data in cookie variable
Correct Answer : Used to store variables of the current session
Correct Answer : 30 secs
<?php class A {} class B {} class C extends A, B {} ?>​
Correct Answer : class C can not extend both A and B
Correct Answer : array_count_values()
Correct Answer : ===
Correct Answer : Used to split a string by a string
Correct Answer : <input name="MyArray[]" />
Correct Answer : $REMOTE_ADDR
Correct Answer : mysql_query()
Correct Answer : imagesy()
Correct Answer : read
Correct Answer : &&&
Correct Answer : mail()
Correct Answer : mysqli_num_rows()
Correct Answer : mysqli_affected_rows()
Correct Answer : 2 MB
Correct Answer : mysql_close()
Correct Answer : @
<?php define("x","5"); $x=x+10; echo x; ?>​
Correct Answer : 5
<?php $x=array(1,3,2,3,7,8,9,7,3); $y=array_count_values($x); echo $y[9]; ?>​
if (null === false) { echo 'true'; } else { echo 'false'; }​
Correct Answer : false
<?php $RESULT = 11 + 011 + 0x11; echo "$RESULT"; ?>​
Correct Answer : 37
Correct Answer : Echo can take multiple parameters where as print cannot
Correct Answer : abstract public function write();
Correct Answer : Numeric Array
Correct Answer : The subject
Correct Answer : print ( )
Correct Answer : trim
Correct Answer : PHP applications can not be compile
Correct Answer : $ alive is true
Correct Answer : func_get_args()
Correct Answer : $_PUT
<?php $a = 5; $b = 5; echo ($a === $b); ?>
Correct Answer : 1
Correct Answer : i), ii), iii) and iv)
<?php function doSomething( &$arg ) { $return = $arg; $arg += 1; return $return; } $a = 3; $b = doSomething( $a ); ?>
Correct Answer : a is 4 and b is 3
Correct Answer : Only ii)
<?php function a() { function b() { echo 'I am b'; } echo 'I am a'; } a(); a(); ?>
Correct Answer : I am a
Correct Answer : Magic Function
Correct Answer : 0
Correct Answer : iii) and iv)
Correct Answer : is_array()
<?php $state = array ("Karnataka", "Goa", "Tamil Nadu", "Andhra Pradesh"); echo (array_search ("Tamil Nadu", $state) ); ?>
Correct Answer : 2
<?php $fruits = array ("apple", "orange", "banana"); echo (next($fruits)); echo (next($fruits)); ?>
Correct Answer : orangebanana
Correct Answer : prev()
<?php $a1 = array("a" => "red", "b" => "green", "c" => "blue", "d" => "yellow"); $result = array_flip($a1); print_r($result); ?>
Correct Answer : Array ( [red] => a [green] => b [blue] => c [yellow] => d )
Correct Answer : Array ( [a] => red [b] => green [c] => blue )
<?php $a = array(12, 5, 2); echo(array_product($a)); ?>
Correct Answer : 120
<?php $number = range(0, 5); print_r ($number); ?>
Correct Answer : Array ( [0] => 0 [1] => 1 [2] => 2 [3] => 3 [4] => 4 [5] => 5 )
<?php $fruits = array ("mango", "apple", "pear", "peach"); $fruits = array_flip($fruits); echo ($fruits[0]); ?>
Correct Answer : error
Correct Answer : natcasesort()
<?php $face = array ("A", "J", "Q", "K"); $number = array ("2","3","4", "5", "6", "7", "8", "9", "10"); $cards = array_merge ($face, $number); print_r ($cards); ?>
Correct Answer : Array ( [0] => A [1] => J [2] => Q [3] => K [4] => 2 [5] => 3 [6] => 4 [7] => 5 [8] => 6 [9] => 7 [10] => 8 [11] => 9 [12] => 10 )
<?php $fruits = array ("apple", "mango", "peach", "pear", "orange"); $subset = array_splice ($fruits, 2); print_r ($fruits); ?>
Correct Answer : Array ( [0] => apple [1] => mango )
<?php $number = array ("4", "hello", 2); echo (array_sum ($number)); ?>
Correct Answer : 6
Correct Answer : Encapsulation
Correct Answer : Polymorphism
Correct Answer : class instantiation
Correct Answer : $obj = new foo ();
Correct Answer : const PI = ‘3.1415’;
Correct Answer : $object->methodName();
Correct Answer : i) and ii)
<?php class Example { public $name; function Sample() { echo "This is an example"; } } ?>
Correct Answer : public $name;
Correct Answer : static
Correct Answer : Final
Correct Answer : function __construct()
Correct Answer : extends
Correct Answer : destinationObject = clone targetObject;
Correct Answer : ii) and iv)
Correct Answer : __clone()
Correct Answer : __call
Correct Answer : 16
Correct Answer : Fatal run-time error
Correct Answer : error_reporting = E_ERROR | E_COMPILE_ERROR | E_CORE_ERROR
Correct Answer : ignore_repeated_errors
Correct Answer : define_syslog_variable()
Correct Answer : syslog()
Correct Answer : PHP 5.3
Correct Answer : Returns the message if it is passed to the constructor
Correct Answer : Standard PHP Library
Correct Answer : filter_var_array()
<?php $num = "123"; if (!filter_var($num, FILTER_VALIDATE_INT)) echo("Integer is not valid"); else echo("Integer is valid"); ?>
Correct Answer : Integer is valid
Correct Answer : Are used to allow or disallow specific characters in a string
<?php $var=300; $int_options = array("options"=>array ("min_range"=>0, "max_range"=>256)); if (!filter_var($var, FILTER_VALIDATE_INT, $int_options)) echo("Integer is not valid"); else echo("Integer is valid"); ?>
Correct Answer : Integer is not valid
<?php $value = 'car'; $result = filter_var($value, FILTER_VALIDATE_BOOLEAN, FILTER_NULL_ON_FAILURE); ?>
Correct Answer : NULL
<?php function convertSpace($string) { return str_replace("_", " ", $string); } $string = "Peter_is_a_great_guy!"; echo filter_var($string, FILTER_CALLBACK, array("options"=>"convertSpace")); ?>
Correct Answer : Peter is a great guy!
Correct Answer : [A-za-z]
Correct Answer : Portable Operating System Interface for Unix
<?php $text = "this is\tsome text that\nwe might like to parse."; print_r(split("[\n\t]",$text)); ?>
Correct Answer : [0] => this is [1] => some text that [2] => we might like to parse.
Correct Answer : Only i)
<?php $foods = array("pasta", "steak", "fish", "potatoes"); $food = preg_grep("/^s/", $foods); print_r($food); ?>
Correct Answer : Array ( [1] => steak )
Correct Answer : strtoupper()
<?php echo str_pad("Salad", 5)." is good."; ?>
Correct Answer : Salad is good
Correct Answer : implode()
Correct Answer : strrpos()
<?php $url = "freetimelearn@example.com"; echo ltrim(strstr($url, "@"),"@"); ?>
Correct Answer : example.com
Correct Answer : bytes
Correct Answer : fileatime()
Correct Answer : file_get_contents()
Correct Answer : fgetss()
Correct Answer : fwrite()
Correct Answer : system()
Correct Answer : scandir()
Correct Answer : String
Correct Answer : E
Correct Answer : mktime()
Correct Answer : getlastmod()
<?php echo "Today is ".date("F d, Y"); ?>
Correct Answer : Today is October 08, 2018
Correct Answer : strtotime(“+45 days”)
Correct Answer : everyone
Correct Answer : $_REQUEST
Correct Answer : GET
Correct Answer : FILTER_VALIDATE_EMAIL
Correct Answer : i) and iv)
Correct Answer : isset()
Correct Answer : Hard-coding a login pair directly into the script
Correct Answer : explode()
Correct Answer : Data-based authentication
Correct Answer : file_uploads
Correct Answer : max_input_time
Correct Answer : PHP 5.2.12
Correct Answer : memory_limit
Correct Answer : upload_tmp_dir “/tmp/phpuploads/ directory”
Correct Answer : $_FILES Array
Correct Answer : is_uploaded_file()
Correct Answer : Domain Name System
Correct Answer : dns_get_record()
Correct Answer : getmxrr()
Correct Answer : $mimemail->addAttachment(‘attachment.pdf’);
Correct Answer : Check whether a valid session exists
Correct Answer : session.save_handler
Correct Answer : URL rewriting
Correct Answer : session.cookie_domain
Correct Answer : session_unset()
Correct Answer : $_SESSION[‘username’] = “Chanti”;
unset($_SESSION['username']); printf("Username now set to: %s", $_SESSION['username']);
Correct Answer : Username now set to:
Correct Answer : session-fixation
Correct Answer : delete_old_session
Correct Answer : SessionHandler::gc
Correct Answer : session_set_save_handler()
Correct Answer : disable_functions = fopen, file
Correct Answer : –enable-memory-limit
Correct Answer : open_basedir = “/home/www/”
Correct Answer : ServerSignature
Correct Answer : AddType application/x-httpd-php .php
<?php $number = array(0,1,two,three,four,5); $num = preg_grep("/[0-5]/", $number); print_r($num); ?>
Correct Answer : Array([0]=>0 [1]=>1 [5]=>5)
Correct Answer : preg_replace()
Correct Answer : preg_matchall
Correct Answer : MySQL
Correct Answer : mysqli
Correct Answer : extension=php_mysqli.dll
Correct Answer : $mysqli = new mysqli()
Correct Answer : $mysqli->select_db('databasename');
Correct Answer : mysqli_connect_errno()
Correct Answer : client code
Correct Answer : is_bool()
Correct Answer : index.php
Correct Answer : .htaccess
Correct Answer : one or more word characters and/or hyphens
Correct Answer : $_GET[‘url’]
Correct Answer : POST admin.php
Correct Answer : Making a method call using parent
Correct Answer : PHP Data Object
Correct Answer : const NAME
Correct Answer : abstract class
Correct Answer : getPrevious()
Correct Answer : overloading
Correct Answer : __call()
Correct Answer : __destruct()
class CopyMe {} $first = new CopyMe(); $second = $first;
Correct Answer : In PHP 4: $second and $first are 2 distinct objects
class StringThing {} $st = new StringThing(); print $st;
Correct Answer : Object id #1
Correct Answer : copied
Correct Answer : namespace my;
Correct Answer : Both do not handle the errors in the same way
Correct Answer : class_exists()
Correct Answer : get_class()
Correct Answer : is_callable()