ITP

BCA - PHP and MySQL

How to create function in PHP

In : BCA Subject : PHP and MySQL

Function Syntax :

function functionName()
{
code to be executed;
}

  • Give the function a name that reflects what the function does
  • The function name can start with a letter or underscore (not a number)

function function_name() // function declare
{
echo "it prashnavali";
}

echo "My name is ";
function_name(); // function call
?>

About us

A truly open platform where you may ask questions and get answers. We also provide comprehensive and easy-to-understand answers to question papers.  discover...

Site status

Flag Counter

Privacy Policy

Sitemap