Recent Posts

What is PHP? PHP programming examples for beginners


What Is PHP?

PHP is a script language Hypertext Preprocessor. PHP is a server-side scripting language so that means that the scripts in PHP are executed on a server now it also supports many databases one of which we'll be using in the future which is MySQL and it's an open-source software so it's free is free to download and to use and best of all it allows web developers to program dynamically generated web pages.

Many Type Databases Supports in PHP (MySql,Oracle,etc).

php,What_is_php,programming,what is php used for,what is php used for,php full form,php is an example of which scripting language,what is php code,php tutorial,php stands for,php vs javascript


PHP Syntax


  1. <?php
  2.             Echo ‘Hello Infodpsoft’ // Print Statement
  3. ?>

Application of PHP 

            - You can create, write, open, read Files.
            - You can Update Database.
            - You can Delete Database.

How to Ues In PHP In HTML Page.


Program




  1. <html>
  2. <head> Infodpsoft</head>
  3. <body>
  4.             <H1>Hello Infodpsoft</H1>
  5.             <?php>
  6.                  Echo  ”Hello Infodpsoft”
  7.             ?>
  8. </body>
  9. </html>

Type of  Datatype in PHP.


            - Array
            - Boolean
            - Doubles
            - Float
            - Integer
            - NULL
            - Object
            - String

How to Declare Variable In PHP.


PHP a Variable Starting in $. Variable can not Startpoint with a number.

Program


  1. <html>
  2. <head> infodpsoft </head>
  3. <body>
  4.             <H1>Hello Infodpsoft</H1>
  5.             <?php
  6.                  $number = 10;
  7.                  Echo $number;
  8.             ?>
  9. </body>
  10. </html>


Doubles 

  1. <html>
  2. <head> Infodpsoft </head>
  3. <body>
  4.             <h1>Double Example</h1>
  5.             <?php
  6.                   $a= 5.10;
  7.                   $b= 10.5;
  8.                   $c= $a + $b;
  9.                   print(" Ans is  $c ");
  10.             ?>
  11. </body>
  12. </html>

Output:
Ans is 15.6







1 comment:

Powered by Blogger.