SlideShare a Scribd company logo
Welcome to AJAX with LAMP Workshop Hussain Fakhruddin [email_address]
Overview of LAMP Introduction Client Server Model, What are web servers What is PHP? Why Use PHP? PHP Crash Course Language Reference: Variables, Controls, Loops etc.
Introduction
What is PHP PHP: Hypertext Preprocessor Why not HTP or HP or HPP? Recursive Acronym An acronym in which the first letter of the first word is represented by the acronym itself. GNU = “GNU is NOT UNIX” PHP: PHP Hypertext Preprocessor
Why Use PHP If you want to add dynamic content to your pages  If you want to make your pages easier to maintain If you’re learning your first "real" computing language  If you need a solution that’s portable across multiple platforms (e.g. Red Hat Linux to Windows 2000) If you like free software or need a free solution Examples of uses of PHP & MySQL: Sign-up Forms Surveys Polls Email a Postcard Content Management
What you need to start a website? What you need? Server PHP parser Configurations.
Some basic configurations Save all your file in Run from browser as http://localhost/  < FILENAME > Open any Text Editor and start coding
PHP Crash Course (cont.) Embedding PHP in HTML <html> <body> <strong>Hello World!</strong><br /> <?php echo ‘My name is HussuLinux!’; ?> </body> </html> PHP tag styles:   XML: <?php ?>, Short: <? ?>, ASP: <% %> Script: <script language=‘php’></script>
PHP Crash Course (cont.) Adding dynamic content by adding the date to the page. <html> <body> <strong>Hello World!</strong><br /> <? echo ‘Today is’; echo date(‘H:i jS F’); ?> </body> </html> Date()   http://www.php.net/manual/en/function.date.php PHP Function Reference  http://www.php.net/manual/en/funcref.php One useful function is phpinfo(). Gives system information so you can quickly find out what’s on your machine.
Using PHP to Query a  MySQL Database <html> <body> <h1>A List of Users Who Have Signed Up For OscarPool</h1> <? $dbh = mysql_connect(&quot;localhost&quot;,“dbusername&quot;,“dbpassword&quot;)   or  die(“Couldn't connect to database.&quot;); $db = mysql_select_db(“dbname&quot;, $dbh)    or  die(“Couldn't select database.&quot;); $sql = “SELECT username, email FROM oscarpool”; $result = mysql_query($sql, $dbh)  or  die(“Something is wrong with your SQL statement.&quot;); while ($row = mysql_fetch_array($result)) { $username = $row[‘username’]; $email = $row[‘email’]; echo ‘<a href=“mailto:’.$email.’”>’.$username.’</a><br />\n’; } ?> </body> </html>
AJAX
What's Ajax the buzzword Stands for Asynchronous JavaScript and XML Its a web development technique. Its Faster and Interactive.
Who uses Ajax? Gmail Google Maps Meebo Ebuddy And many more
Technology behind AJAX
Why Ajax? Faster, Increase Interactivity Rich User Experience
Steps to AJAX Create a  XMLHttpRequest  request object Tell the request object where to send the request Tell the object what to do when the request is answered Tell the object to make a request
Lets Code <script language = &quot;javascript&quot;> var XMLHttpRequestObject = false; if (window.XMLHttpRequest) { XMLHttpRequestObject = new XMLHttpRequest (); }  else if (window.ActiveXObject) { XMLHttpRequestObject = new ActiveXObject (&quot;Microsoft.XMLHTTP&quot;); } if (XMLHttpRequestObject) { document.write (&quot;<h1>Welcome to AJAX</h1>&quot;); } </script>
PHP & MySQL Resources Web Sites http://www.php.net/ http://www.phpbuilder.com/ http://www.devshed.com/ http://www.phpmyadmin.net/ http://www.hotscripts.com/PHP/ http://www.mysql.com/ http://www.owasp.org/ Books PHP and MySQL Web Development 2 nd  Edition, Welling & Thomson Web Database Applications with PHP & MySQL, O’Reilly Publishers PHP Cookbook, O’Reilly Publishers MySQL Cookbook, O’Reilly Publishers
My special Thanks to: David Olsen ( [email_address] ) for his help in presentation's content. PHP Freaks ( http://www.phpfreaks.com ) This is where I learnt PHP from

More Related Content

What's hot (20)

PDF
Introduction to Web Technology
Rob Bertholf
 
PDF
Hosting
Fajar Baskoro
 
PDF
HTTP
Daniel Kummer
 
PPTX
Web technologies: HTTP
Piero Fraternali
 
PDF
Web Fundamental
SiliconExpert Technologies
 
KEY
What's up with HTTP?
Mark Nottingham
 
PPTX
Web (HTTP) request to response life cycle
Gopakumar Kunduveetil
 
PDF
4 Basic PHP
Jalpesh Vasa
 
PPT
Class 1 - World Wide Web Introduction
Ahmed Swilam
 
PDF
Intro to Dynamic Web Pages
Jussi Pohjolainen
 
PPTX
Http
NITT, KAMK
 
PPTX
An Introduction to HTTP
Keerthana Krishnan
 
PPTX
HTTP
vaibhavrai1993
 
PPTX
Http request and http response
Nuha Noor
 
PPT
KMUTNB - Internet Programming 2/7
phuphax
 
PPTX
HTTP
altaykarakus
 
PPT
Introduction About PHP
Software company
 
ODP
Web Server-Side Programming Techniques
guest8899ec02
 
PPT
Http request&response by Vignesh 15 MAR 2014
Navaneethan Naveen
 
Introduction to Web Technology
Rob Bertholf
 
Hosting
Fajar Baskoro
 
Web technologies: HTTP
Piero Fraternali
 
Web Fundamental
SiliconExpert Technologies
 
What's up with HTTP?
Mark Nottingham
 
Web (HTTP) request to response life cycle
Gopakumar Kunduveetil
 
4 Basic PHP
Jalpesh Vasa
 
Class 1 - World Wide Web Introduction
Ahmed Swilam
 
Intro to Dynamic Web Pages
Jussi Pohjolainen
 
Http
NITT, KAMK
 
An Introduction to HTTP
Keerthana Krishnan
 
Http request and http response
Nuha Noor
 
KMUTNB - Internet Programming 2/7
phuphax
 
HTTP
altaykarakus
 
Introduction About PHP
Software company
 
Web Server-Side Programming Techniques
guest8899ec02
 
Http request&response by Vignesh 15 MAR 2014
Navaneethan Naveen
 

Similar to Linux Apache Php Mysql Lamp1273 (20)

PPT
PHP MySQL
Md. Sirajus Salayhin
 
PPT
Open Source Package Php Mysql 1228203701094763 9
isadorta
 
PPT
Open Source Package PHP & MySQL
kalaisai
 
PPTX
Php
samirlakhanistb
 
PPT
Introduction To Php For Wit2009
cwarren
 
PPTX
PHP Hypertext Preprocessor
adeel990
 
PPTX
Php
khushbulakhani1
 
ODP
PHP BASIC PRESENTATION
krutitrivedi
 
PDF
Php summary
Michelle Darling
 
PPTX
Jquery in web development, including Jquery in HTML
backiyalakshmi14
 
PDF
PHP Basics
Roohul Amin
 
PPT
Intro to-php-19 jun10
Kathy Reid
 
PPT
PHP and MySQL
bmani
 
PPT
Phpwebdevelping
mohamed ashraf
 
PPT
PHP - Introduction to PHP Fundamentals
Vibrant Technologies & Computers
 
PPTX
PHP language presentation
Annujj Agrawaal
 
PPTX
Php reports sumit
Sumit Biswas
 
PPT
Phpwebdev
Luv'k Verma
 
PPTX
Quick beginner to Lower-Advanced guide/tutorial in PHP
Sanju Sony Kurian
 
PPTX
Introduction to PHP.pptx
SherinRappai
 
Open Source Package Php Mysql 1228203701094763 9
isadorta
 
Open Source Package PHP & MySQL
kalaisai
 
Introduction To Php For Wit2009
cwarren
 
PHP Hypertext Preprocessor
adeel990
 
PHP BASIC PRESENTATION
krutitrivedi
 
Php summary
Michelle Darling
 
Jquery in web development, including Jquery in HTML
backiyalakshmi14
 
PHP Basics
Roohul Amin
 
Intro to-php-19 jun10
Kathy Reid
 
PHP and MySQL
bmani
 
Phpwebdevelping
mohamed ashraf
 
PHP - Introduction to PHP Fundamentals
Vibrant Technologies & Computers
 
PHP language presentation
Annujj Agrawaal
 
Php reports sumit
Sumit Biswas
 
Phpwebdev
Luv'k Verma
 
Quick beginner to Lower-Advanced guide/tutorial in PHP
Sanju Sony Kurian
 
Introduction to PHP.pptx
SherinRappai
 
Ad

More from hussulinux (7)

ODP
Effective communication
hussulinux
 
PPT
Enterprise Application Framework
hussulinux
 
PPT
Direct Web Remoting : DWR
hussulinux
 
PDF
Auto Forex Trade with Meta Trader 4
hussulinux
 
PPT
Apache Ant
hussulinux
 
ODP
Mobile Navigation
hussulinux
 
PDF
Flash Widget Tutorial
hussulinux
 
Effective communication
hussulinux
 
Enterprise Application Framework
hussulinux
 
Direct Web Remoting : DWR
hussulinux
 
Auto Forex Trade with Meta Trader 4
hussulinux
 
Apache Ant
hussulinux
 
Mobile Navigation
hussulinux
 
Flash Widget Tutorial
hussulinux
 
Ad

Recently uploaded (20)

PDF
NLJUG Speaker academy 2025 - first session
Bert Jan Schrijver
 
DOCX
Cryptography Quiz: test your knowledge of this important security concept.
Rajni Bhardwaj Grover
 
PPTX
The Project Compass - GDG on Campus MSIT
dscmsitkol
 
PPTX
From Sci-Fi to Reality: Exploring AI Evolution
Svetlana Meissner
 
PDF
UiPath DevConnect 2025: Agentic Automation Community User Group Meeting
DianaGray10
 
PDF
Newgen 2022-Forrester Newgen TEI_13 05 2022-The-Total-Economic-Impact-Newgen-...
darshakparmar
 
PDF
SIZING YOUR AIR CONDITIONER---A PRACTICAL GUIDE.pdf
Muhammad Rizwan Akram
 
PPTX
Mastering ODC + Okta Configuration - Chennai OSUG
HathiMaryA
 
PPTX
MuleSoft MCP Support (Model Context Protocol) and Use Case Demo
shyamraj55
 
PDF
Future-Proof or Fall Behind? 10 Tech Trends You Can’t Afford to Ignore in 2025
DIGITALCONFEX
 
PDF
Reverse Engineering of Security Products: Developing an Advanced Microsoft De...
nwbxhhcyjv
 
PDF
Automating Feature Enrichment and Station Creation in Natural Gas Utility Net...
Safe Software
 
PPTX
Future Tech Innovations 2025 – A TechLists Insight
TechLists
 
PDF
NASA A Researcher’s Guide to International Space Station : Physical Sciences ...
Dr. PANKAJ DHUSSA
 
PPTX
AI Penetration Testing Essentials: A Cybersecurity Guide for 2025
defencerabbit Team
 
PDF
“Voice Interfaces on a Budget: Building Real-time Speech Recognition on Low-c...
Edge AI and Vision Alliance
 
PDF
POV_ Why Enterprises Need to Find Value in ZERO.pdf
darshakparmar
 
PDF
Go Concurrency Real-World Patterns, Pitfalls, and Playground Battles.pdf
Emily Achieng
 
PDF
Newgen Beyond Frankenstein_Build vs Buy_Digital_version.pdf
darshakparmar
 
PPTX
Q2 FY26 Tableau User Group Leader Quarterly Call
lward7
 
NLJUG Speaker academy 2025 - first session
Bert Jan Schrijver
 
Cryptography Quiz: test your knowledge of this important security concept.
Rajni Bhardwaj Grover
 
The Project Compass - GDG on Campus MSIT
dscmsitkol
 
From Sci-Fi to Reality: Exploring AI Evolution
Svetlana Meissner
 
UiPath DevConnect 2025: Agentic Automation Community User Group Meeting
DianaGray10
 
Newgen 2022-Forrester Newgen TEI_13 05 2022-The-Total-Economic-Impact-Newgen-...
darshakparmar
 
SIZING YOUR AIR CONDITIONER---A PRACTICAL GUIDE.pdf
Muhammad Rizwan Akram
 
Mastering ODC + Okta Configuration - Chennai OSUG
HathiMaryA
 
MuleSoft MCP Support (Model Context Protocol) and Use Case Demo
shyamraj55
 
Future-Proof or Fall Behind? 10 Tech Trends You Can’t Afford to Ignore in 2025
DIGITALCONFEX
 
Reverse Engineering of Security Products: Developing an Advanced Microsoft De...
nwbxhhcyjv
 
Automating Feature Enrichment and Station Creation in Natural Gas Utility Net...
Safe Software
 
Future Tech Innovations 2025 – A TechLists Insight
TechLists
 
NASA A Researcher’s Guide to International Space Station : Physical Sciences ...
Dr. PANKAJ DHUSSA
 
AI Penetration Testing Essentials: A Cybersecurity Guide for 2025
defencerabbit Team
 
“Voice Interfaces on a Budget: Building Real-time Speech Recognition on Low-c...
Edge AI and Vision Alliance
 
POV_ Why Enterprises Need to Find Value in ZERO.pdf
darshakparmar
 
Go Concurrency Real-World Patterns, Pitfalls, and Playground Battles.pdf
Emily Achieng
 
Newgen Beyond Frankenstein_Build vs Buy_Digital_version.pdf
darshakparmar
 
Q2 FY26 Tableau User Group Leader Quarterly Call
lward7
 

Linux Apache Php Mysql Lamp1273

  • 1. Welcome to AJAX with LAMP Workshop Hussain Fakhruddin [email_address]
  • 2. Overview of LAMP Introduction Client Server Model, What are web servers What is PHP? Why Use PHP? PHP Crash Course Language Reference: Variables, Controls, Loops etc.
  • 4. What is PHP PHP: Hypertext Preprocessor Why not HTP or HP or HPP? Recursive Acronym An acronym in which the first letter of the first word is represented by the acronym itself. GNU = “GNU is NOT UNIX” PHP: PHP Hypertext Preprocessor
  • 5. Why Use PHP If you want to add dynamic content to your pages If you want to make your pages easier to maintain If you’re learning your first &quot;real&quot; computing language If you need a solution that’s portable across multiple platforms (e.g. Red Hat Linux to Windows 2000) If you like free software or need a free solution Examples of uses of PHP & MySQL: Sign-up Forms Surveys Polls Email a Postcard Content Management
  • 6. What you need to start a website? What you need? Server PHP parser Configurations.
  • 7. Some basic configurations Save all your file in Run from browser as http://localhost/ < FILENAME > Open any Text Editor and start coding
  • 8. PHP Crash Course (cont.) Embedding PHP in HTML <html> <body> <strong>Hello World!</strong><br /> <?php echo ‘My name is HussuLinux!’; ?> </body> </html> PHP tag styles: XML: <?php ?>, Short: <? ?>, ASP: <% %> Script: <script language=‘php’></script>
  • 9. PHP Crash Course (cont.) Adding dynamic content by adding the date to the page. <html> <body> <strong>Hello World!</strong><br /> <? echo ‘Today is’; echo date(‘H:i jS F’); ?> </body> </html> Date() http://www.php.net/manual/en/function.date.php PHP Function Reference http://www.php.net/manual/en/funcref.php One useful function is phpinfo(). Gives system information so you can quickly find out what’s on your machine.
  • 10. Using PHP to Query a MySQL Database <html> <body> <h1>A List of Users Who Have Signed Up For OscarPool</h1> <? $dbh = mysql_connect(&quot;localhost&quot;,“dbusername&quot;,“dbpassword&quot;) or die(“Couldn't connect to database.&quot;); $db = mysql_select_db(“dbname&quot;, $dbh) or die(“Couldn't select database.&quot;); $sql = “SELECT username, email FROM oscarpool”; $result = mysql_query($sql, $dbh) or die(“Something is wrong with your SQL statement.&quot;); while ($row = mysql_fetch_array($result)) { $username = $row[‘username’]; $email = $row[‘email’]; echo ‘<a href=“mailto:’.$email.’”>’.$username.’</a><br />\n’; } ?> </body> </html>
  • 11. AJAX
  • 12. What's Ajax the buzzword Stands for Asynchronous JavaScript and XML Its a web development technique. Its Faster and Interactive.
  • 13. Who uses Ajax? Gmail Google Maps Meebo Ebuddy And many more
  • 15. Why Ajax? Faster, Increase Interactivity Rich User Experience
  • 16. Steps to AJAX Create a XMLHttpRequest request object Tell the request object where to send the request Tell the object what to do when the request is answered Tell the object to make a request
  • 17. Lets Code <script language = &quot;javascript&quot;> var XMLHttpRequestObject = false; if (window.XMLHttpRequest) { XMLHttpRequestObject = new XMLHttpRequest (); } else if (window.ActiveXObject) { XMLHttpRequestObject = new ActiveXObject (&quot;Microsoft.XMLHTTP&quot;); } if (XMLHttpRequestObject) { document.write (&quot;<h1>Welcome to AJAX</h1>&quot;); } </script>
  • 18. PHP & MySQL Resources Web Sites http://www.php.net/ http://www.phpbuilder.com/ http://www.devshed.com/ http://www.phpmyadmin.net/ http://www.hotscripts.com/PHP/ http://www.mysql.com/ http://www.owasp.org/ Books PHP and MySQL Web Development 2 nd Edition, Welling & Thomson Web Database Applications with PHP & MySQL, O’Reilly Publishers PHP Cookbook, O’Reilly Publishers MySQL Cookbook, O’Reilly Publishers
  • 19. My special Thanks to: David Olsen ( [email_address] ) for his help in presentation's content. PHP Freaks ( http://www.phpfreaks.com ) This is where I learnt PHP from