The Twin Blades Blue Version - PowerPoint PPT Presentation

1 / 26
About This Presentation
Title:

The Twin Blades Blue Version

Description:

Basics and uses of php Prepared By ... delete, and close files on the server PHP can collect form data PHP can send and receive cookies PHP can add, ... – PowerPoint PPT presentation

Number of Views:127
Avg rating:3.0/5.0
Slides: 27
Provided by: powerp225
Category:
Tags: blades | blue | cookies | twin | version

less

Transcript and Presenter's Notes

Title: The Twin Blades Blue Version


1
Basics and uses of php
Prepared By
www.thesmartpath.in
Powerpoint Templates
2
Index
  • What is PHP  
  • Features of PHP
  • What PHP can do
  • What is PHP file
  • Versions of PHP PHP 5
  • Versions of PHP PHP 6 and Unicode
  • Versions of PHP PHP 7
  • Installing PHP
  • PHP Syntax
  • PHP variables
  • PHP Comments
  • PHP Variables

3
Index
  12. Rules for declaring variables
13. PHP Variables Scope 14.
PHP Data Types 15. Uses of PHP - e
commerce 16. Uses of PHP - Project
Management 17. Uses of PHP Desktop
Application 18. Uses of PHP - Web
Templates 19. Uses of PHP Parsing
XML Files 20. PHP and MYSQL 21.
PHP and MYSQL (About MYSQL)
4
What is php
  •  
  • PHP is an acronym for "PHP Hypertext
    Preprocessor
  • PHP is a widely-used, open source scripting
    language
  • PHP scripts are executed on the server
  • PHP is free to download and use

5
Features of php
  • PHP runs on various platforms (Windows, Linux,
    Unix, Mac OS X, etc.)
  • PHP is compatible with almost all servers used
    today (Apache, IIS, etc.)
  • PHP supports a wide range of databases
  • PHP is free. Download it from the official PHP
    resource www.php.net
  • PHP is easy to learn and runs efficiently on the
    server side

6
What php can do
  • PHP can generate dynamic page content
  • PHP can create, open, read, write, delete, and
    close files on the server
  • PHP can collect form data
  • PHP can send and receive cookies
  • PHP can add, delete, modify data in your database
  • PHP can be used to control user-access
  • PHP can encrypt data

7
What is php file
  • PHP files can contain text, HTML, CSS,
    JavaScript, and PHP code
  • PHP code are executed on the server, and the
    result is returned to the browser as plain HTML
  • PHP files have extension ".php

8
Versions of php php 5
On July 13, 2004, PHP 5 was released, powered
by the new Zend Engine II. PHP 5 included new
features such as improved support for
object-oriented programming, the PHP Data Objects
(PDO) extension (which defines a lightweight and
consistent interface for accessing databases),
and numerous performance enhancements. In 2008
PHP 5 became the only stable version under
development. Late static binding had been missing
from PHP and was added in version 5.3. Many
high-profile open-source projects ceased to
support PHP 4 in new code as of February 5, 2008,
because of the GoPHP5 initiative provided by a
consortium of PHP developers promoting the
transition from PHP 4 to PHP 5.
9
Versions of php php6
PHP 6 and UNICODE PHP received mixed reviews due
to lacking native Unicode support at the core
language level. In 2005, a project headed by
Andrei Zmievski was initiated to bring native
Unicode support throughout PHP, by embedding the
International Components for Unicode (ICU)
library, and representing text strings as UTF-16
internally. Since this would cause major changes
both to the internals of the language and to user
code, it was planned to release this as version
6.0 of the language, along with other major
features then in development.
10
Versions of php php 7
Php 7 PHP 7 gets its foundations from an
experimental PHP branch that was originally named
phpng (PHP next generation), which aims at
optimizing PHP performance by refactoring the
Zend Engine while retaining near-complete
language compatibility. As of 14 July 2014,
WordPress-based benchmarks, which serve as the
main benchmark suite for the phpng project, show
an almost 100 increase in performance. Changes
from phpng are also expected to make it easier to
improve performance in the future, as more
compact data structures and other changes are
seen as better suited for a successful migration
to a just-in-time (JIT) compiler. Because of the
significant changes, this reworked Zend Engine
will be called Zend Engine 3, succeeding the Zend
Engine 2 used in PHP 5.
11
Installing php
  • Set up php on your own pc
  • However, if your server does not support PHP,
    you must
  • install a web server
  • install PHP
  • install a database, such as MySQL
  • Use web host with php support
  • If your server has activated support for php
  • a) create some .php files and place them in
    web directory server will
  • b) automatically parse them for you
  • Because PHP is FREE most web hosts offer php
    support

12
Php - Syntax
Basic php Syntax Php script can bé placed
anywhere in document A php script starts with
lt?php and ends with ?gt lt?php // php code Goes
hère ?gt The default file extension of PHP is
 .php  A php file contains normally HTML tags
and PHP script code In PHP keywords such
as(if- else echo, while etc) are NOT case
sensitive
13
Php - Comments
  • Comments in PHP
  • A comment in PHP code is a line that is not
    read/executed as part of the program. Its only
    purpose is to be read by someone who is looking
    at the code.
  • Comments can be used to
  • Let others understand what you are doing
  • Remind yourself of what you did - Most
    programmers have experienced coming back to
    their own work a year or two later and having to
    re-figure out what they did. Comments can remind
    you of what you were thinking when you wrote the
    code

14
Php - variables
  • Php 5 variables
  • Creating (Declaring) PHP Variables
  • In PHP, a variable starts with the sign,
    followed by the name of the variable
  • Using PHP Variables
  • A variable can have a short name (like x
    and y) or
  • A more descriptive name (age, carname,
    total_volume).

15
  • Rules for PHP declaring variables
  • A variable starts with the sign, followed by
    the name of the variable
  • A variable name must start with a letter or the
    underscore character
  • A variable name cannot start with a number
  • A variable name can only contain alpha-numeric
    characters and underscores (A-z, 0-9, and _ )
  • Variable names are case-sensitive (age and
    AGE are two different variables)

16
Php-variables Scope
  • Php 5 variables scope
  • In PHP, variables can be declared anywhere in the
    script. The scope of a variable is the part of
    the script where the variable
  • can be referenced/used.
  • PHP has three different variable scopes
  • local
  • global
  • static

17
Php Data Types
  • Php 5 Data Types
  • PHP supports following data types
  • String
  • Integer
  • Float
  • Boolean
  • Array
  • Object
  • Resource

18
Uses of php - e-commerce
1. E-commerce E-commerce is one of the
major uses for PHP. From a small business level
to an enterprise level, businesses are always
looking to create additional streams of revenue
online. If you know how to integrate existing
e-commerce solutions or build your own from
scratch, this gives you a distinct advantage with
your clients.
19
Uses of php Project mangement
2. Project Management Tools For both
freelancers and web development firms alike,
project management is an important aspect of your
business. Your clients need a resource to be able
to check the progress of the work and provide
feedback. Ideally, with a good project management
system in place, your clients will be thoroughly
pleased with the end result.

20
Uses of php- Desktop applications
  • 3. GUI Interface
  • For those of you who are up to the challenge, you
    can extend your PHP installation to create
    desktop applications. This one is a challenge
    because it requires some extensive knowledge of
    PHP and it might also be easier to create desktop
    applications in other programming languages. If
    PHP is your favorite programming language, then
    you can use some of these PHP extensions to get
    you started creating GUI applications.
  • PHP GTK - This extension is a popular open
    source that GIMP toolkit
  • ZZEE PHP GUI - A paid solution that allows
    you to turn your PHP scripts
  • into windows applications.

21
Uses of php-web templates
4. Creating dynamic website templates Using
PHP, you can make it easier to add pages and
elements to your websites dynamically. You begin
by creating the HTML page and splitting it into
the header, main content, and footer sections.
Add the .php extension to your subsequent pages
and use server-side Includes for the header and
footer for each new page. You can also have
dynamic sidebars and top navigation sections. As
a matter of fact, the more "templated" your site
is, the easier it is to update the content.

22
Uses of php - Parsing XML files
5. Parsing XML Files PHP allows you to parse
XML files. Parsing XML is an important feature of
PHP 5 because not all browsers can output the
contents of an XML file so you can create a
parser in PHP to facilitate this process. Using
XML is important for RSS feeds, and also for data
storage and rendering data on different devices -
for example, cell phones use an implementation of
XML called WML (Wireless Markup Language).
Working with XML files in PHP is similar to
handling the opening, closing, and reading of a
file. The steps involved are creating an XML
parser, setting functions to handle your opening
and closing XML tags, opening the file for
reading, reading the file incrementally and then
closing it.
23
Uses of php-parsing XML files

24
Php and MYSQL
Php MySQL database With PHP, you can connect
to and manipulate databases. MySQL is the most
popular database system used with PHP. The data
in a MySQL database are stored in tables. A table
is a collection of related data, and it consists
of columns and rows. Databases are useful for
storing information categorically. Facts about
MySQL database MySQL is the de-facto standard
database system for web sites with HUGE volumes
of both data and end-users (like Facebook,
Twitter, and Wikipedia). Another great thing
about MySQL is that it can be scaled down to
support embedded database applications.
25
Php and MYSQL
  • About MySQL
  • MySQL is a database system used on the web
  • MySQL is a database system that runs on a
    server
  • MySQL is ideal for both small and large
    applications
  • MySQL is very fast, reliable, and easy to use
  • MySQL uses standard SQL
  • MySQL compiles on a number of platforms
  • MySQL is free to download and use
  • MySQL is developed, distributed, and supported
    by Oracle Corporation

26
Thank You
Write a Comment
User Comments (0)
About PowerShow.com