?
What will be the output of the following PHP code ?
What will be the output of the following PHP code ?
<?php
function constant()
{
define("GREETING", "Welcome to Narnia");
echo greeting;
}
?>
<?php
function constant()
{
define("GREETING", "Welcome to Narnia");
echo greeting;
}
?>
Answer & Solution
Correct Answer:
Option
D
By default constants are case sensitive. Hence an error will arise.
Join the Discussion
Login to post a comment or share your explanation.
Login