ALWAR INSTITUTE OF ENGINEERING & TECHNOLOGY

Slides:



Advertisements
Similar presentations
IS 6116 Introduction – 10 Jan Lecturer Details Aonghus Sugrue Website: aonghussugrue.wordpress.com
Advertisements

PHP I.
BY: ALBERTO CABEZAS 4/19/2010. INTRODUCTION: PHP is considered today as one of the most famous scripting languages. PHP is widely used as a general purpose.
Server-Side vs. Client-Side Scripting Languages
Web Programming Language Dr. Ken Cosh Week 1 (Introduction)
WHAT IS PHP PHP is an HTML-embedded scripting language primarily used for dynamic Web applications.
PHP By Dr. Syed Noman Hasany. PHP PHP was originally created by Rasmus Lerdorf in PHP stands for PHP: Hypertext Preprocessor (a recursive acronym).
8/17/2015CS346 PHP1 Module 1 Introduction to PHP.
Web Page A page displayed by the browser. Website Collection of multiple web pages Web Browser: A software that displays web pages on client computer.
Sys Prog & Scripting - HW Univ1 Systems Programming & Scripting Lecture 15: PHP Introduction.
Languages in WEB Presented by: Jenisha Kshatriya BCM SS09.
Chapter 16 The World Wide Web Chapter Goals Compare and contrast the Internet and the World Wide Web Describe general Web processing Describe several.
Basics of Web Databases With the advent of Web database technology, Web pages are no longer static, but dynamic with connection to a back-end database.
IDK0040 Võrgurakendused I harjutus 06: PHP: Introduction Deniss Kumlander.
16-1 The World Wide Web The Web An infrastructure of distributed information combined with software that uses networks as a vehicle to exchange that information.
CPS120: Introduction to Computer Science The World Wide Web Nell Dale John Lewis.
PHP Professor Waterman. Agenda What is PHP Versions HTML Dynamic Web sites Interactive Web Sites Installing PHP Transfer pages to a Web hosting service.
Nael Alian Introduction to PHP
PHP With Oracle 11g XE By Shyam Gurram Eastern Illinois University.
10/5/2015CS346 PHP1 Module 1 Introduction to PHP.
Universiti Utara Malaysia Chapter 3 Introduction to ASP.NET 3.5.
1Computer Sciences Department Princess Nourah bint Abdulrahman University.
Introduction to PHP Advanced Database System Lab no.1.
ASP. What is ASP? ASP stands for Active Server Pages ASP is a Microsoft Technology ASP is a program that runs inside IIS IIS stands for Internet Information.
David Lawrence 7/8/091Intro. to PHP -- David Lawrence.
IT ELECTIVE 2.  Web server Can refer to either the hardware (the computer) or the software (the computer application) that helps to deliver content that.
PHP Introduction PHP is a server-side scripting language.
An Investigation into using a Document Management System Presented by: Bijal RanaSupervisor: John Ebden.
ASP. ASP is a powerful tool for making dynamic and interactive Web pages An ASP file can contain text, HTML tags and scripts. Scripts in an ASP file are.
1) PHP – Personal Home Page Scripting Language 2) JavaScript.
8 th Semester, Batch 2009 Department Of Computer Science SSUET.
 Before you continue you should have a basic understanding of the following:  HTML  CSS  JavaScript.
1 PHP Intro PHP Introduction After this lecture, you should be able to: Know the fundamental concepts of Web Scripting Languages in general, PHP in particular.
Web Page Designing With Dreamweaver MX\Session 1\1 of 9 Session 1 Introduction to PHP Hypertext Preprocessor - PHP.
A S P. Outline  The introduction of ASP  Why we choose ASP  How ASP works  Basic syntax rule of ASP  ASP’S object model  Limitations of ASP  Summary.
PHP is a server scripting language, and a powerful tool for making dynamic and interactive Web pages. PHP is a widely-used, free, and efficient alternative.
Introduction to PHP. PHP Origins Rasmus LerdorfRasmus Lerdorf (born Greenland, ed Canada) PHP originally abbreviation for ‘Personal Home Pages’, now ‘PHP.
Presented By Sushil K. Chaturvedi Assistant Professor SRCEM,Banmore 1.
PHP Basics and Syntax Lesson 3 ITBS2203 E-Commerce for IT.
PHP using MySQL Database for Web Development (part II)
Web Programming Language
Tonga Institute of Higher Education IT 141: Information Systems
Introduction to Dynamic Web Programming
WWW and HTTP King Fahd University of Petroleum & Minerals
CSC 301 Web Programming Charles Frank.
Introduction and Principles
And Why You Should Use It In You Websites
ALWAR INSTITUTE OF ENGINEERING & TECHNOLOGY
Introduction to PHP “PHP is a server-side scripting language designed specifically for the Web. Within an HTML page, you can embed PHP code that will be.
* Lecture # 7 Instructor: Rida Noor Department of Computer Science
Introduction to PHP “PHP is a server-side scripting language designed specifically for the Web. Within an HTML page, you can embed PHP code that will be.
PHP / MySQL Introduction
BASIC PHP and MYSQL Edward S. Flores.
PHP Introduction.
Database Driven Websites
Chapter 27 WWW and HTTP.
Tonga Institute of Higher Education IT 141: Information Systems
Module 1 Introduction to PHP 11/30/2018 CS346 PHP.
PHP.
JavaScript.
Tonga Institute of Higher Education IT 141: Information Systems
IntroductionToPHP Static vs. Dynamic websites
Chapter 16 The World Wide Web.
Intro to PHP.
Tutorial 6 PHP & MySQL Li Xu
Introduction to World Wide Web
An Introduction to JavaScript
Introduction to PHP.
PHP an introduction.
Web Application Development Using PHP
Presentation transcript:

ALWAR INSTITUTE OF ENGINEERING & TECHNOLOGY A PTS REPORT ON PHP AT XTVISTA, NOIDA Presented By: FACULTY CO-ORDINATOR: SUMIT SHARMA NEETU YADAV B.TECH 4TH YR, 7TH SEM I.T.

ABOUT THE COMPANY: XTVISTA XTVISTA offers a wide spectrum of technical courses and application courses designed to suit every skill level, as well as the ability to consult directly with organizations to tailor made learning plans for any number of employees. XTVISTA products and services have a wide appeal and are applicable those in varied positions including network administrators, systems analysts, systems architects,  test engineers, software developers, help desk staff, IT managers, senior executives, administrative assistants and business professionals.

TRAINING IN COMPANY The Company also provides educational trainings to students in various technologies like -> c/c++ .NET TECHNOLOGY JAVA TECHNOLOGY+ PHP++ADVANCE RED HAT LINUX VLSI TECHNOLOGY EMBEDDED SYSTEMS ORACLE+ etc.

Presentation Outline MEANS OF PHP WHAT IS PHP HISTORY OF PHP WHY PHP INTRODUCTION TO HTML ADVANTAGES OF PHP

MEANS OF PHP Meaning of Hypertext Preprocessor: PHP stands for PHP: Hypertext Preprocessor PHP Hypertext Preprocessor is a widely used, general-purpose scripting language that was originally designed for web development. Meaning of Hypertext Preprocessor: Hypertext Preprocessor has no specific meaning but It is commonly used to extract data out of a database and present it on the Web page. PHP can also be used to connect to a database; to retrieve, add or update content. This makes PHP an ideal language for creating large-scale websites. The output from the PHP functions on the page are typically returned as HTML code, which can be read by the browser. NT/2000 and Unix Web servers support the language, and it is widely used with the M SQL database.

WHAT IS PHP? PHP is an open-source server-side, HTML embedded scripting language. The goal of the language is to allow Web developers to write dynamically generated pages quickly. The primary advantage to server-side scripting is the ability to highly customize the response based on the user's requirements, access rights, or queries into data stores. Originally designed as a high level scripting language for producing dynamic web pages that are generated from information accessed from a My SQL database. A dynamic Web page interacts with the user, so that each user visiting the page sees customized information.

HISTORY OF PHP PHP originally stood for personal home page. This is the first use of the name "PHP". First version of PHP (1.0)– designed by Rasmus Lerdorf in June 1995 written in the C programming language. Next version of PHP (2.0)– launched in November 1997. Next release of PHP 3(3.0) launched in June 1998. In May 2000 – PHP 4(4.0) powered by Zend Engine1.0 was released. (More advanced two-stage parse/execute tag-parsing system called the Zend engine.) In July 2004 – PHP 5(5.0) was released powered by Zend Engine II. In June 2009 – PHP 5(5.3) was released. Now PHP6.0 is released.

WHY PHP? In an HTML page, PHP code is enclosed within special PHP tags. When a visitor opens the page, the server processes the PHP code and then sends the output (not the PHP code itself) to the visitor's browser. It means that, unlike Java script, we don't have to worry that someone can steal our PHP script. PHP is compatible with almost all servers used today like apache. PHP is easy to learn and runs efficiently on the server side. PHP runs on different platforms like Linux, Windows, Unix. PHP is free software released under the PHP License, which is incompatible with the GNU General Public License (GPL) because of restrictions on the use of the term PHP. PHP offers excellent connectivity to many databases including My SQL, Informix, Oracle, Sybase, Solid, Postgre SQL.

Introduction to HTML HTML stands for HYPER TEXT TRANSFER PROTOCOL HTML was first introduced on the internet by Berners-Lee in late 1991. HTML is a language used for describing web pages. HTML markup tags are usually called html tags.

Structure of an HTML document <head> <title>Title of page</title> </head> <body> This is an example of simple<b>HTML document</b> </body> </html>

OUTPUT

Advantages of PHP Open-source Easy to use ( C-like and Perl-like syntax) Stable and fast Multiplatform Many databases support Many common built-in libraries Pre-installed in Linux distributions

PHP - What it do? Client from browser send HTTP request (with POST/GET variables) Apache recognizes that a PHP script is requested and sends the request to PHP module PHP interpreter executes PHP script, collects script output and sends it back Apache replies to client using the PHP script output as HTML output Load PHP File Web Page Request PHP Engine – Run Script PHP Results HTML Response

PHP Momentum

Steps to using PHP PHP documents are text files that can be created with any text editor. (A “real” code editor such as Ace HTML is better.) Figure out where to store PHP documents. With the Windows IIS server, they are stored in /Inetpub/www root. Create and edit PHP documents in an editor. Execute the documents from your browser. With Windows IIS the “URL” is localhost/{PHP file name}. Make required changes in your editor and “refresh” the application in your browser.

PHP Status on the Internet

Apache and PHP When a file ends in .php, is not simply sent down the http connection like other files. Instead, apache reads the file. If it finds PHP parts in the file, it sends them to the PHP processor. This processor is a model that lives inside Apache.

The Magic of PHP The client never sees the PHP code. It only sees what the PHP processor has done with the code. You can write normal HTML code, and you can switch to writing PHP code pretty much at any stage. You can have several PHP parts. PHP parts can not be nested. The contents of the PHP part can be called a PHP script.

Statements Like a normal text is split into sentences, a PHP script is split into statements. A PHP script contains 1 or more statements. Each statements tells the interpreter something. Each statement is ended by a semicolon. In our first script there is only one statement. Think of a statement like a rule in CSS. But never forget the semicolon!

Expressions The stuff before the semicolon is called an expression. You can think of an expression as anything anyone may want to write in a computer program. So an expression is just a way to talk about “stuff” in a program in a more edifying way than just calling it “stuff”.

Functions phpinfo() is a function. Functions are one of the most fundamental concepts in computer programming. A function is an expression that does something to something else. The “something else” is in the parenthesis. It is called the argument of the function. phpinfo() is a function. Its argument is empty.

A quick example <html> <head>Test page</head> <body> The time is now <?php echo date(); ?> <hr> </body> </html>

A quick example <html> <head>Test page</head> <body> The time is now <?php here we “jump into” php echo date(); ?> here we “jump” back out <hr> </body> </html>

Running PHP Application http://my.server.com/webmail.php WEB BROWSER HTTP Request SQL APACHE HTTP Response Windows OS PHP SQL UQERY RESULT SET LINUX OS CLIENT SERVER

WHAT IS A SESSION VARIABLE Session variables are used to store information for a particular period of time. The values in session variables exist only till the session exists. They are used to carry information from one page to another of a web site. We can create a session using a session identifier and store it in the server. When the client makes any request, the data stored in the session variable can be accessed by PHP any number of times until the session is ended.

NEED OF SESSION VARIABLE In web sites, passing information between pages using a query string is very difficult. For example once you log into a site, passing the username to all the pages of the site using query string is very difficult, but this can be done easily using Session variables. These variables can be used to pass information from one page to another without using a query string, since it is easy to maintain and retrieve.

HOW SET SESSION VARIABLE Session variables can set using 'session_register‘ function in PHP as shown below: Syntax: session_register("string"); // string - mention the name of the session variable Example: session_register("Username"); Username - name of the session variable

DESTROY SESSION VARIABLE They can be destroyed using 'session_destroy' function. This is used to end a session when the user logs out. The code for destroying all the session variables stored in the server is given below: Syntax: session_destroy(); Example: session_destroy(); session_unregister("string"); //string - name of the session variable Example: session_unregister("Username"); Username - name of the session variable

WHAT IS A COOKIE. A cookie is flat file based system used to represent a user of the website. It is stored on the local computer of the user. When you visit a website a cookie may be set to represent the user. Next time he visits the website, he does not need to identify himself manually; instead the cookie will represent him on that website. With the help of PHP, cookies can be created, read and destroyed.

THANK YOU QUERIES