What will be the output of the following PHP code?
<?php
$str = addslashes('What does "yolo" mean?');
echo($str);
?>
<?php
$str = addslashes('What does "yolo" mean?');
echo($str);
?>
A. What does /”yolo/” mean?
B. What does ”yolo” mean?
C. What does ”yolo” mean?
D. What does ”yolo” mean?
Answer: Option C
Solution(By Examveda Team)
The addslashes() function returns a string with backslashes in front of predefined characters.Join The Discussion
Comments ( 1 )
Related Questions on Functions
Which one of the following is the right way of defining a function in PHP?
A. function { function body }
B. data type functionName(parameters) { function body }
C. functionName(parameters) { function body }
D. function fumctionName(parameters) { function body }
A. Call By Value
B. Call By Reference
C. Default Argument Value
D. Type Hinting
wrong anwser!