WEBVTT

00:01.040 --> 00:04.280
I will call you back again to another video lecture in PHP.

00:04.490 --> 00:09.620
In this video lecture I will go ahead and talk about the URL parameter.

00:16.370 --> 00:16.820
All right.

00:16.820 --> 00:24.440
So the URL parameter I'm going to talk about is how we receive information from the users in PHP using

00:24.440 --> 00:25.850
the method gate.

00:26.840 --> 00:31.070
Let's go ahead and go back right in here and create this form again.

00:31.070 --> 00:36.410
So go ahead and close this and I'm going to close this form.

00:36.440 --> 00:40.430
Then I go ahead and uh just like we do.

00:40.460 --> 00:42.380
I'll go right here and give the name of this.

00:42.380 --> 00:43.370
We need to go.

00:43.400 --> 00:48.020
That is, go ahead and give the site name that is PHP.

00:48.050 --> 00:49.670
That is the file we are working with.

00:49.670 --> 00:54.440
And then this method is what I want to talk about the gate method.

00:54.440 --> 00:57.110
So I've just added that right in there.

00:57.110 --> 01:00.290
So let me go ahead and say I need a name.

01:00.290 --> 01:01.730
So I'll just give it a name prompt.

01:01.730 --> 01:09.940
And then we go ahead and uh use the input tag and the type is going to be text.

01:09.970 --> 01:17.350
Then we go ahead and give it a name and let the name be username.

01:19.270 --> 01:19.720
All right.

01:19.720 --> 01:21.970
So go ahead and choose an input tag.

01:21.970 --> 01:26.860
And go ahead and put just submit a submit button.

01:26.860 --> 01:32.590
So it is going to be submit and close this.

01:33.730 --> 01:34.210
All right.

01:34.240 --> 01:39.070
Now right in here I'll go ahead and uh save this.

01:39.100 --> 01:40.540
Let's go ahead and refresh and check it out.

01:40.540 --> 01:41.800
So we have this right in here.

01:41.800 --> 01:46.090
And then let's go ahead and uh equal this out.

01:46.090 --> 01:57.010
So equal then underscore get and uh we want to get is the username the username.

01:57.880 --> 01:58.690
All right.

01:58.690 --> 02:01.750
So I'm going to open up this.

02:02.980 --> 02:03.430
All right.

02:03.460 --> 02:09.430
So let's go ahead and drag this open a little bit I'll go ahead and open this.

02:09.460 --> 02:11.110
My Brasa.

02:11.140 --> 02:12.580
I'm going to shift you right in here.

02:12.610 --> 02:15.940
This guy and I shift this again so that we can see what we're doing.

02:16.840 --> 02:19.720
All right, so I've shifted this, and I have this name here.

02:19.720 --> 02:26.920
So if I go ahead and put a George and if I hit on submit, you can see that I have George.

02:26.920 --> 02:32.140
And now right up here you can see that I have visa name equal to George.

02:32.140 --> 02:38.530
This was displayed on that and it makes that not secured.

02:39.040 --> 02:43.600
So over here you can see I have a username equal to George.

02:43.630 --> 02:50.110
And you will be wondering ever since you are visiting websites you have never seen that happen.

02:50.590 --> 02:53.200
So why should we have that right in there?

02:53.650 --> 03:00.730
It is not secured and we will shift this a little bit again so that I can be able to explain more on

03:00.730 --> 03:01.150
this.

03:01.150 --> 03:07.480
So let's go ahead and drag this right in here because we need to work on this URL parameters and we

03:07.480 --> 03:09.670
will understand what we are doing.

03:12.010 --> 03:12.400
All right.

03:12.400 --> 03:18.370
Now you can see that this is not very secured because it's in a password.

03:18.370 --> 03:19.990
You're going to see the password right in here.

03:19.990 --> 03:26.860
And I can actually go and say because we have site dot PHP and this question mark goes username equal

03:26.860 --> 03:27.400
to these.

03:27.400 --> 03:35.620
So what if someone go ahead and put in ampersand and uh let me say so I have this which we did previously

03:35.650 --> 03:37.930
say ampersand age equals 24.

03:37.930 --> 03:39.160
If I go ahead I click on this.

03:39.190 --> 03:40.750
Nothing actually happens.

03:40.750 --> 03:44.320
But if I go right in here I change the username to age.

03:44.350 --> 03:46.510
Save this refresh.

03:46.540 --> 03:49.000
You can see I have 24 printed out here.

03:49.210 --> 03:53.320
Even though we don't have this, it's being saved on the URL.

03:54.250 --> 03:55.090
You can see that.

03:55.090 --> 03:57.850
So it means we need to secure.

03:57.880 --> 04:01.000
This is very very important though.

04:01.000 --> 04:03.970
This is a very good rule in Google.

04:04.000 --> 04:05.530
Let's say we go over to Google.

04:05.560 --> 04:07.090
Let's open up Google.

04:07.090 --> 04:12.190
And uh Google is one of the platforms that you use expose URL.

04:12.220 --> 04:13.720
I don't actually know why they do that.

04:13.720 --> 04:19.900
So we can see just like we have here, if we go back to Google and search this like let me say Cat,

04:20.720 --> 04:22.250
Um, I just cut.

04:22.280 --> 04:23.690
Now look over here.

04:23.720 --> 04:25.970
Google has the URL exposed.

04:26.000 --> 04:28.100
I don't actually know why they did that.

04:28.130 --> 04:28.940
You understand?

04:28.940 --> 04:34.790
So you see slash Q equal to cut and ampersand equal to all this.

04:34.790 --> 04:36.290
So I don't know why they did it.

04:36.290 --> 04:42.080
Now if I go ahead and, uh, copy whatever that is here I'll get to the end.

04:42.110 --> 04:44.060
I'm copying everything to the end.

04:44.090 --> 04:48.290
And when I get to the end, I'll delete this from the Google URL.

04:48.320 --> 04:52.670
I can go to slash for, like, cattle and type cattle.

04:52.700 --> 04:55.220
Remember, I'm not doing this from the page.

04:55.220 --> 04:56.420
I'm doing it from the URL.

04:56.420 --> 05:00.260
And if I hit on cattle, it'll go ahead and search about cattle.

05:00.950 --> 05:01.670
You see that?

05:03.260 --> 05:03.590
All right.

05:03.620 --> 05:07.610
Now you're going to go ahead and change this to, uh, let me say.

05:10.730 --> 05:12.530
Let's put the name George.

05:15.980 --> 05:18.590
You can see it gives me everything concerning George.

05:18.770 --> 05:21.500
And if it were to change this to.

05:24.110 --> 05:25.130
A minimum level.

05:25.130 --> 05:28.490
Available, and it's going to give us a written about memoir.

05:29.030 --> 05:29.750
We see that.

05:29.750 --> 05:33.440
So this is one of the things that Google does.

05:33.470 --> 05:37.820
They expose URL and we can go back to Cato.

05:37.850 --> 05:44.120
Let's say Cato and leave this right in here because I love the pictures and this is being shown.

05:44.150 --> 05:44.840
All right.

05:44.840 --> 05:48.620
So you can see that Google expose a URL and you can search from there.

05:48.650 --> 05:50.270
Just like what we are doing right in here.

05:50.300 --> 05:55.340
But this is more secured because you can't penetrate a Google uh, database.

05:55.370 --> 05:59.300
You can enter through their server is more secure than whatever you are doing.

05:59.330 --> 06:07.250
Google actually high use high technology than medium to be very strong that you, Perry, can interfere

06:07.250 --> 06:08.090
with your server.

06:08.090 --> 06:14.630
But if you should leave yours open, I bet you within 24 hours you will be hacked.

06:14.660 --> 06:17.300
You will be hacked, I tell you that.

06:17.330 --> 06:23.990
So for us to be more secure, we needed to do more on this URL parameter.

06:23.990 --> 06:32.230
So we need to get over here and talk about something secured Sunderbans to use, which is very important.

06:32.230 --> 06:37.270
So I've made this to get us to know more on what is really going on.

06:37.390 --> 06:44.470
Then also the fact that we are not secured and living our parameters in the URL and our users and the

06:44.500 --> 06:48.910
hackers can actually grab them and use them against us.

06:49.330 --> 06:56.560
I am going to teach us how we can be able to secure this URL without displaying the usernames, the

06:56.860 --> 07:03.520
profile, the password, everything on the URL which is not really good because if someone get this

07:03.520 --> 07:06.730
guy and change this name to password.

07:07.420 --> 07:16.660
And now let's go back here and uh, okay, let's go over here and uh, see this is going to be password.

07:16.720 --> 07:17.200
All right.

07:17.230 --> 07:24.280
Now if I should if I should change copy this and change the H to password, I'm going to save this.

07:24.280 --> 07:26.290
And let's go ahead and refresh this.

07:26.290 --> 07:29.440
And uh, let's kind of remove this.

07:29.440 --> 07:37.570
So if I go over here and input the name let me see the password I'm going to say hello, and I can see

07:37.570 --> 07:38.650
that nobody sees that.

07:38.650 --> 07:40.570
And let's go ahead and submit this and check it out.

07:40.600 --> 07:41.320
Hello.

07:41.740 --> 07:44.110
If you win, I printed it out.

07:44.320 --> 07:47.260
Oh, let's go ahead and say we are open to print this out.

07:47.260 --> 07:51.580
So on one hand please this this is again a refresh.

07:51.670 --> 07:57.940
Now I'm going to change the password to be entered in.

07:57.940 --> 08:01.630
And uh I will say what I'm doing.

08:01.660 --> 08:03.010
Now let me submit that.

08:03.010 --> 08:07.630
And over here on the URL you can see hello world.

08:08.170 --> 08:12.400
It is more secure because my password is on the URL and people can copy this.

08:12.400 --> 08:17.920
And that is why we are going to look on something more secure in the next video lecture.

08:17.920 --> 08:19.300
So get started.

08:19.330 --> 08:20.230
Move over there.

08:20.530 --> 08:27.730
Let's go ahead and deal with this and secure this URL because it is very important in programming.

08:27.730 --> 08:30.880
So thank you so much and I'm good to see you over there.

08:30.880 --> 08:34.060
If you have any question on this use the question and answer section.

08:34.060 --> 08:37.240
And I'm going to get back to you as soon as possible.

08:37.270 --> 08:38.350
Thank you so much.

08:38.350 --> 08:40.900
And I'm going to see you in the next video lecture.
