Thursday, 22 March 2018

Introduction of PHP

Introduction of PHP

PHP  Training in Chandigarh is the best option for the freshers like the students or the people which are a noob to the corporate world. The hypertext preprocessor is widely known as PHP .  It is most commonly used scripting language. Php scripts are executed on the server and the result is returned to the browser as a plain HTML. Moreover it is free to download and use.PHP use several cms( content management system )like Wordpress,Joomla,cake Php,Drupal etc...

 What actually Php files are?

Php files are usually not only consists of Php codes.
There are other files used in PHP  like JavaScript, HTML and CSS or other Texts.
These Php files are then saved by the .php extension.
Php can create dynamic page content and can be run on various platforms like
Mac OS X
Unix etc.

Php can create, Open, read, write and delete files on the server. Php is compatible with almost all the servers like IIS, Apache, etc.
Php can send and receive cookies and can collect form data. It can also encrypt

What are Php functions?

Php consists of nearly 1000 built-in functions, other than that we can create our own functions. There are various user defined functions.Before we talk about user defined functions, the first thing to know is:

what actually a function is?

“A function is usually a block of statement that can be used repeatedly in a program”.
A function will not execute immediately while the loading of the page.
A call to a function helps in executing a Function.
 How can we use User Defined functions in Php?
A function name should starts with a Letter or an Underscore.
Function names are not Case-Sensitive.


      Function functionname(){
Code to be executed;

Php Function Arguments :   

An argument is just like a variable. The information is passed to functions with the help of an Argument. Arguments are specified under the function name inside the Parentheses. The user can add as many arguments of their choice by separating them with the comma.
The following example has a function with one argument($fname). When the function Family Name() is called, we can also pass along a name( eg. jane), and the name is used inside the function which outputs several different First names but the same Last name.
Function familyname($fname){
      echo”$fname Refsnes.<br>”;
Php default Argument Value
The following program is about the usage of Default parameter. If we call the function SetGrades() without arguments it takes the default value as an argument.

Function SetGrades($minGrades = F){
        echo”the Grade is  :  $minGrade <br>”;
setGrade();                //will use the default value F
 If you want to learn more about this so please visit : PHP Training in Chandigarh



Post a Comment