Sign In | Subscribe
Start learning today, and be successful in your academic & professional career. Start Today!
Loading video...
This is a quick preview of the lesson. For full access, please Log In or Sign up.
For more information, please see full course syllabus of Advanced PHP
  • Discussion

  • Download Lecture Slides

  • Table of Contents

  • Transcription

  • Related Services

Bookmark and Share
Lecture Comments (1)

0 answers

Post by Jonathan Bello on June 28, 2012

When you say know the material from your previous course. Does this mean know it of the top of your head and know how to implement it or just understand the concepts and have good idea about it?

I have previous programming knowledge, understand most of the concepts you have taught in your previous course. I can look at code and have a pretty good understanding of what it is doing.

Course Introduction

Lecture Slides are screen-captured images of important points in the lecture. Students can download and print out these lecture slide images to do practice problems as well as take notes while watching the lecture.

  • Intro 0:00
  • Advanced PHP w/ MySQL 0:13
    • Course Introduction
    • Course Content
  • Web Application: Educator Store 1:45
    • Web Application: Educator Store
  • Object-Oriented Programming 6:09
    • Object-Oriented Programming Overview
  • MySQL 6:50
    • MySQL Overview
    • Example: Command Prompt & MySQL
  • What You Will Learn 9:34
    • What You Will Learn
  • Course Prerequisites 11:52
    • Course Prerequisites

Transcription: Course Introduction

Hello, and welcome to the first lecture in Educator.com's Advanced PHP with MySQL course.0000

In today's lesson, we are going to be providing an overview of all the topics covered in the course, as well as briefly discussing the prerequisites required.0006

This is, as the name implies (Advanced PHP with MySQL) an advanced PHP course that is aimed at 0016

prior PHP developers--developers that already have PHP experience.0022

And what it is aimed at is teaching those developers to be able to add database-driven functionality to their website.0026

We are going to be learning how to integrate a MySQL database into your web applications.0034

This course is specifically a direct continuation of the Introduction to PHP course that I have taught here at Educator.com.0039

And so, it is not a prerequisite that you have taken this course, but for those of you that have taken that course here,0048

you will be able to see how the material from there is going to continue directly in this course.0054

The content of this advanced course is going to break down into three different categories.0060

We are going to be covering advanced PHP concepts, which is going to be stuff like learning about how to perform file input and output.0064

We are going to be learning about how to use sessions, and then cookies, and so forth.0071

This course is also going to provide an introduction to object-oriented programming, so it assumes you have no prior knowledge of that.0077

We are going to learn about the basics of what object-oriented programming is and how to use it in PHP.0084

And we are going to provide an introduction to what databases are--specifically, the MySQL database.0089

And we are going to cover the basics of the most common SQL commands (which is a structured query language)0095

(which are commands that you use to interact with a database).0101

A main feature of this course is building up this mock web application that we call the Educator Store.0106

We are going to be continuing building upon the application that we developed in the introductory course.0113

And what we do--the way the course is going to proceed--is that I am going to introduce topics;0119

we are going to go over some lecture examples; we will have a homework assignment; 0124

and then, we are going to take the material that we have learned and integrate it into this web application, 0127

so we can see the material learned in a real-world example.0132

More or less, what is going to happen is: we will have one lesson on material and new topics, and then we'll have a lecture that follows that0137

that is integrating that material into this web application.0144

If we go ahead and take a look at our Educator Store website, this is the application that we are going to be developing.0149

It is a simple store with a number of different departments in it, where you have different items that you can choose,0159

that has information about the items that we are going to be able to pull from a database.0167

You will be able to add items to your cart; so, for example, we can add a basketball and a T-shirt.0171

You will be able to remove items from the cart.0180

You can check out; and what that will allow you to do is enter, for example, shipping information.0182

I'll just show you quickly what this looks like.0191

And what you will be able to do is go ahead and submit an order, and it will store the order in the database.0200

We are going to be developing, on the front end of the store, this Shopping Cart functionality that we have just looked at.0206

On the back side, we are going to be creating an administrator website called the Educator Admin site,0212

where we will be able to log in, and then perform administrative functions on the site.0217

For example, we will be able to add a new department to the store, if we wanted to, using this interface.0225

Let's create a department called Winter Clothes.0230

And then we can add items to our department, so we would be able to select the Winter Clothes department, and we want to add our winter jacket to it.0236

And then, add it to our department; and then, what we will be able to do is: this is going to be making changes directly in our MySQL database.0244

And then, now, when we go back to our homepage, we will be able to directly see that those changes on the admin site show up in the store.0250

So now, we have a Winter Clothes department; we can see that it has this winter jacket that was already in another department.0256

And we can add it to a cart and check out with it, just as before.0261

Additionally, there is a View Order section of this administrative website where you will be able to go0265

and view any orders that users have placed.0271

For example, we can look at the second order that was placed, that was of this value at this time; and this is the order that we have just placed.0274

And it shows the item number and the quantity and so forth.0279

And so, it is going to store information about those orders; and we are going to learn how to implement all this.0282

Initially, a lot of this is going to be done in a file database system.0285

We are going to learn about file input and output to implement the storage of this data (for example, information about the items in the departments) in files.0290

Then, we are going to migrate it, as the course progresses, over into a MySQL database,0299

and then just continue to add functionality to it, such as being able to update things, delete things...0303

for example, deleting departments, being able to view orders, and so forth.0308

And then, as part of our user authentication, we will be able to log out.0312

And so, we will learn how to implement a basic user authentication log in/log out system.0315

As mentioned, what we will be creating is a session-based shopping cart that is going to utilize cookies,0326

which is a term you may have heard about before; if not, we are going to learn about that in the course.0332

We are going to learn how to create a MySQL back end for this website that is going to allow us to store0336

all of the data about the store's items, about its departments, about orders placed...0341

And then, we are going to be developing that separate administrative interface to do things like we saw,0346

like adding new departments, deleting departments, being able to view orders, and so forth.0351

And we are going to learn how to implement a basic user authentication system for that0355

that is going to allow us, when a user logs in, to verify against a MySQL database 0359

if that username and password for a particular user are valid, for example.0364

As far as object-oriented programming goes, this course is going to provide an introduction to it.0371

So, we are going to assume no prior knowledge of object-oriented programming.0376

Some of the topics that we are going to talk about, as it relates to object-oriented programming, are classes and objects,0380

which are two terms you may have heard used before, and they are basic object-oriented functionality programming concepts.0386

We are going to be learning about those; we are going to be learning how to create your own user-defined classes.0391

And then, we are going to learn how you can use object-oriented functionality to improve your code, and to make it more flexible, for example.0399

So, we are going to learn about the benefits of why you also use object-oriented programming.0407

MySQL, as you likely know (if you chose to take this course), is called an RDBMS (Relational Database Management System).0413

And it is a system that is used to manage and store large amounts of data.0423

For example, maybe you have a store with 1,000 items in it, and you want to store all of the information about it.0427

Or you have 100 customers, and you want to store all of their addresses, and so forth.0431

You typically use a relational database to do that; and MySQL is a relational database with a system built on top of it0436

that allows you to manage that database and interact with it.0443

A main feature of this course is that, not only will we be learning about how to set up a MySQL database and how to interact with it0447

(using what is known as SQL, which is Structured Query Language), but we are also going to learn, 0453

as importantly, how to do that from PHP code.0457

There are two different topics we are going to be covering: we are going to be covering how to use the database/how to set up a database,0460

and then we are going to cover how to take what we know about databases and implement that0465

so that we can interact with it in our PHP code.0469

As far as interacting with databases, students are going to learn how to query a database (which is to request information from a database--0472

for example, say "give me all of the orders in the database that were placed in the last month").0480

You are also going to learn about inserting, updating, and deleting entries in the database.0486

And these directly correspond to SQL (Structured Query Language) commands, which you may have heard about before.0491

And then, when you query a database, it is known as a select command.0499

And so, we are going to learn about these four different commands and how to use them, first just using a database0503

as you would just in plain MySQL, and then also through PHP.0511

For example, one of the things that we are going to be doing is actually working at the Command Prompt.0515

There is a program we are going to learn about called MySQL Monitor, which allows you to connect to a MySQL database0520

and do things like run queries and run these SQL commands we were talking about.0526

For example, something you will learn about is a select query.0531

Let's say we want to pull up information about all of the items in our particular store.0538

We can run a query from this MySQL Monitor program--and this is something you are going to see run live in the code in the lectures.0544

And you will be able to see the results of that.0552

And so, what you are going to do is: you are going to learn about the commands, and then you are also going to get to see them in action.0553

This is our way of teaching MySQL and SQL and how to run commands and how to learn about MySQL databases.0559

And then, we are going to move it and shift it over to where we are going to be doing this sort of interaction,0566

not from a command line, but from a PHP program.0570

Just to cover a little more specifically the topics that we are going to examine in this course,0576

we are going to learn about file input and output; we are going to learn how to read from, and how to write to, files.0581

We are going to learn the details of the HTTP POST method, and specifically, we are going to learn how to upload files using HTTP POST method.0587

And what that is going to allow us to do is: on our administrative interface site, when we add a new item to the store,0595

as you saw in the store, all of our items have the images: we are going to learn how to upload an image for a new item, for example.0600

And we are going to learn about the details of the HTTP POST method in order to do that.0606

And if you don't know what that is, we will be learning about that in this course.0611

As mentioned, we are going to be covering the basics of object-oriented programming.0615

We are also going to talk a bunch about what cookies are and something known as state.0618

And we are going to talk about how we can use cookies and functionality built into PHP to implement sessions.0623

What that is going to allow us to do is implement our Shopping Cart.0629

And sessions...if you don't have experience with that, that is fine; we are going to be learning about that.0631

That is going to allow you to track one user interaction from another.0636

So, for example, when a user adds an item to a shopping cart, and then they view another item,0641

like when you go to amazon.com, for example--you can see, "OK, you have one item in your cart."0645

Well, you implement that functionality using sessions, and we are going to learn about that.0649

We are going to learn about how to set up a MySQL database and what a MySQL database is and how to interact with it on a basic level.0654

We are going to talk about the details of SQL, the Structured Query Language.0661

As mentioned, we are going to learn about the select command, and we are also going to learn about 0666

the insert, update, and delete commands, which are the foremost command commands that you will be using with MySQL.0670

And so, we are going to learn about how to use those in this MySQL Monitor client program.0676

And then, we are going to learn how to implement those in PHP (which, actually, is this next bullet point).0682

We are going to learn how to access a MySQL database from PHP.0686

And then, we are also going to learn how to implement a basic user authentication system,0690

where we are going to take what we have learned about using MySQL from PHP, and be able to query or request information from0694

our MySQL database, and say, "Does this user exist in the database with this username and password?"0702

And we are going to show how to implement restricting access to pages, based on whether that user exists or not.0707

You may have already figured out the course prerequisites from what we talked about in the slides.0714

You just need a solid understanding of the basics of the PHP language.0719

And what I am going to use as the defining characteristics of the prerequisites for the course are0725

is that you have an understanding of all the material covered in my Introduction to PHP course here at Educator.com.0732

So, the only knowledge that you will need to know about PHP is anything that has been covered in that course.0739

If it hasn't been covered in there, you don't need to know about it.0744

So, for those of you that have not taken that course, and have some PHP experience, you can go there and look at the lessons 0747

and see if you understand everything; and if not, take lessons and learn about the material that is going to be used in this course.0753

And also, you can use it as a way to review any material to prepare for this course.0759

It is also assumed that, for this course, students are going to have no prior experience with either object-oriented programming or working with databases.0766

And that is one of the main features of this course: that we are going to be, for databases, for example,0777

assuming you have never worked with a database before; so we are going to teach you the basics of0782

how to set it up, how to create it, how to interact with it, and then how to use it from PHP.0785

And then, object-oriented programming--we are going to introduce that as if you have no object-oriented programming background.0790

If you have background with either of these, that is great--it is going to help in understanding the material.0796

But definitely, this course was designed so that you don't need to have prior knowledge or experience with these two areas.0801

That ends today's lesson; thank you for watching Educator.com--I look forward to seeing you next time.0810