+ All Categories
Home > Technology > Php Introduction

Php Introduction

Date post: 11-Feb-2017
Category:
Upload: amit-patil
View: 314 times
Download: 0 times
Share this document with a friend
44
Transcript
Page 1: Php Introduction
Page 2: Php Introduction

Vincent Pontier aka Elroubio – Creator Of elePHPant

 PHP mascot

Page 3: Php Introduction

THREE-TIERED WEB SITE: WAMP/LAMP

Page 4: Php Introduction

SERVER SIDE TECHNIQUES

• PHP• Java EE: Servlet, JSP• .NET• CGI / Perl (Very old)• Ruby• …

Page 5: Php Introduction

HISTORYPHP (PHP: Hypertext Preprocessor) was created by Rasmus Lerdorf in 1994. It was initially developed for HTTP usage logging and server-side form generation in Unix.

PHP 2 (1995) transformed the language into a Server-side embedded scripting language. Added database support, file uploads, variables, arrays, recursive functions, conditionals, iteration, regular expressions, etc.

PHP 3 (1998) added support for ODBC data sources, multiple platform support, email protocols (SNMP,IMAP), and new parser written by Zeev Suraski and Andi Gutmans .

PHP 4 (2000) became an independent component of the web server for added efficiency. The parser was renamed the Zend Engine. Many security features were added.

PHP 5 (2004) adds Zend Engine II with object oriented programming, robust XML support using the libxml2 library, SOAP extension for interoperability with Web Services, SQLite has been bundled with PHP

PHP 6 and Unicode(2005) lacking native Unicode support at the core language level

PHP 7(2015) (PHP next generation), which aims at optimizing PHP performance by refactoring the Zend Engine while retaining near-complete language compatibility.

Page 6: Php Introduction

WHAT IS PHP?

• PHP is a scripting language that was originally designed for web development to produce dynamic webpages.

• For this purpose, PHP code is embedded into HTML

• PHP originally stood for ”PERSONAL HOME PAGE” - now -  Hypertext Preprocessor

• Installed on more than 240 million websites

• Cost-effective, Scope for Customization, Faster, Preferred over others

Page 7: Php Introduction

USAGE• PHP is a general-purpose scripting language that is especially

suited to server-side web development where PHP generally runs on a web server.

• PHP code in a requested file is executed by the PHP runtime, usually to create dynamic web page content.

• PHP is also used for command-line scripting and client-side GUI applications.

• PHP can be deployed on most web servers, many operating systems and platforms, and can be used with many relational database management systems.

Page 8: Php Introduction

RESOURCES• PHP includes free and open source libraries.

• PHP is a fundamentally Internet-aware system.

• Many database servers, embedded SQL libraries such as embedded PostgreSQL, MySQL and SQLite, LDAP servers, and others.

• PHP allows developers to write extensions in C to add functionality to the PHP language.

• These can then be compiled into PHP or loaded dynamically at runtime.

Page 9: Php Introduction

PHP SYNTAX

Page 10: Php Introduction

PHP KEYWORDS

Page 11: Php Introduction

PHP TAG

Page 12: Php Introduction

PROGRAM

Page 13: Php Introduction

DEVELOPMENT ENVIRONMENT

Page 14: Php Introduction

WHITESPACE & COMMENTS

Page 15: Php Introduction

ECHO VS PRINT

Page 16: Php Introduction

SINGLE (‘) VS DOUBLE (“) QUOTES

Page 17: Php Introduction

OPERATORS

Page 18: Php Introduction

ARITHMETIC OPERATORS

Page 19: Php Introduction

COMPARISON OPERATORS

Page 20: Php Introduction

LOGICAL OPERATORS

Page 21: Php Introduction

COMBINATION OPERATORS

Page 22: Php Introduction

OPERATOR PRECEDENCE

Page 23: Php Introduction

CONTROLLING THE FLOW

Page 24: Php Introduction
Page 25: Php Introduction
Page 26: Php Introduction

REPEATING CODE

Page 27: Php Introduction
Page 28: Php Introduction

ARRAYS

Page 29: Php Introduction

INDEXED ARRAYS

Page 30: Php Introduction

ASSOCIATIVE ARRAYS

Page 31: Php Introduction

FUNCTION

Page 32: Php Introduction

RETURN FROM FUNCTION

Page 33: Php Introduction

CODE REUSE

Page 34: Php Introduction

FUNCTION

Page 35: Php Introduction

PHP FRAMEWORKS

Page 36: Php Introduction
Page 37: Php Introduction
Page 38: Php Introduction
Page 39: Php Introduction
Page 40: Php Introduction
Page 41: Php Introduction
Page 42: Php Introduction
Page 43: Php Introduction

INFORMATION• Usual file extensions .php, .phtml .php5 .phps• Paradigm imperative, object-oriented• Appeared in : 1995[1]• Designed by : Rasmus Lerdorf• Developer :The PHP Group• Typing discipline Dynamic, weak• Major implementations Zend Engine, Roadsend PHP, Phalanger,

Quercus, Project Zero, HipHop• Influenced by C, Perl, Java, C++, Tcl[1]• Influenced PHP4Delphi• Programming language : C• OS : Cross-platform• License : PHP License• Website : http://www.php.net

Page 44: Php Introduction

THANK YOU

[email protected]


Recommended