+ All Categories
Home > Documents > Brief Introduction of PHP - Uppsala UniversityPHP-Characteristics Database Connected (eg.PHP&MySQL)...

Brief Introduction of PHP - Uppsala UniversityPHP-Characteristics Database Connected (eg.PHP&MySQL)...

Date post: 24-Aug-2020
Category:
Upload: others
View: 4 times
Download: 0 times
Share this document with a friend
10
Brief Introduction of PHP ---Xue Wu
Transcript
Page 1: Brief Introduction of PHP - Uppsala UniversityPHP-Characteristics Database Connected (eg.PHP&MySQL) Compatible Object Oriented Programming

Brief Introductionof PHP

---Xue Wu

Page 2: Brief Introduction of PHP - Uppsala UniversityPHP-Characteristics Database Connected (eg.PHP&MySQL) Compatible Object Oriented Programming

PHP (Personal Home Page)

Web development 1. can be embedded into HTML 2. generally runs on a web server3. Act as a filter: (from PHP 4, performance improved by

complied input as bytecode) 4. widely used and free charge

Page 3: Brief Introduction of PHP - Uppsala UniversityPHP-Characteristics Database Connected (eg.PHP&MySQL) Compatible Object Oriented Programming

PHP-Characteristics Database Connected (eg. PHP&MySQL) Compatible Object Oriented Programming

Page 4: Brief Introduction of PHP - Uppsala UniversityPHP-Characteristics Database Connected (eg.PHP&MySQL) Compatible Object Oriented Programming

PHP--- example Grammatical:---Can be both embedded into HTML and

separated from HTML code: <? . . . ?>

<?php . . . ?> (XML passers )<script language="php"> . . . </script><% . . . %>

Page 5: Brief Introduction of PHP - Uppsala UniversityPHP-Characteristics Database Connected (eg.PHP&MySQL) Compatible Object Oriented Programming

PHP---Usage Competitor: Microsoft’s Active Server PageSun Microsystems’ Java Server PageMode_perl

Rapid Application Development (RAD)Cake PHP, PRADO, Symfony, Codelgniter

Page 6: Brief Introduction of PHP - Uppsala UniversityPHP-Characteristics Database Connected (eg.PHP&MySQL) Compatible Object Oriented Programming

PHP--- example Annotation: /*C style, Multiple lines*/// C style one line#Unix Style

Page 7: Brief Introduction of PHP - Uppsala UniversityPHP-Characteristics Database Connected (eg.PHP&MySQL) Compatible Object Oriented Programming

PHP--- Interaction with THML: echoCan output multiple strings:<?

$a="hello";$b="world";echo "a","b";?>

---result: hello world

PrintCan only output single string:<?

$a="hello";$b="world";print "a","b";?>

---Parse error: parse error ind:adminmyphphometest.php3 on line 54

Page 8: Brief Introduction of PHP - Uppsala UniversityPHP-Characteristics Database Connected (eg.PHP&MySQL) Compatible Object Oriented Programming

PHP---Security To prevent from damaging on your website1. Error Report2. SQL Injections3. Cross Site Scripting4. Session Security

Page 9: Brief Introduction of PHP - Uppsala UniversityPHP-Characteristics Database Connected (eg.PHP&MySQL) Compatible Object Oriented Programming

PHP---Security

5. Directory traversal6. Cross-site request forgery7. Remote file inclusion

Page 10: Brief Introduction of PHP - Uppsala UniversityPHP-Characteristics Database Connected (eg.PHP&MySQL) Compatible Object Oriented Programming

Reference http://en.wikipedia.org/wiki/PHP last

retrieved on 2009-2-28 http://www.phpchina.com/?action_thematici

nfoview_itemid_34132.html “PHP tutorial”,last retrieved on 2009-2-28

http://www.phpfreaks.com/tutorial/php-security/page9 “PHP Security”, last retrievedon 2009-3-1


Recommended