PHP Functions

Built-in Function

My name has 10 characters.

User-Defined Function

Hello, my name is Varun Sain.

I use functions to perform a specific task in my PHP program. PHP already has built-in functions such as strlen(), which counts characters in text. I can also create my own function when I need it. After I create my function, I can call it to run the code inside it.