1 00:00:00,870 --> 00:00:01,860 Welcome back everyone. 2 00:00:01,860 --> 00:00:07,740 All right so we had to change the text and I've shown you how to use variables and what variables are. 3 00:00:07,910 --> 00:00:10,940 But one thing we need to do is take an input from the user. 4 00:00:10,950 --> 00:00:13,500 Now this is pretty much what computer programming is. 5 00:00:13,530 --> 00:00:20,590 You take input and you do something with it so it reacts to the input that that is that is in the computer 6 00:00:20,610 --> 00:00:22,360 is actually fairly simple. 7 00:00:22,470 --> 00:00:29,010 So what we need to do is you need to just type in inputs and it's pretty simple just like an input like 8 00:00:29,010 --> 00:00:29,640 this. 9 00:00:29,640 --> 00:00:34,960 And you'll notice that an input box comes up like this and you can type in whatever text you want there. 10 00:00:35,220 --> 00:00:39,100 But we do need to type in a couple of the things we need to type in the word type. 11 00:00:39,420 --> 00:00:42,710 And you can put in just text like this. 12 00:00:42,900 --> 00:00:49,050 And this way it will only take in text so remember how I told you there was integers strings and booleans 13 00:00:49,050 --> 00:00:52,110 and all these different kinds of variables in this input box. 14 00:00:52,110 --> 00:00:53,800 We're just going to be taken in text. 15 00:00:53,850 --> 00:00:57,420 And the reason why this is important is that if you ever want to add numbers together you do have to 16 00:00:57,420 --> 00:00:58,880 take in a different kind. 17 00:00:58,890 --> 00:00:59,580 All right. 18 00:00:59,580 --> 00:01:04,560 The second thing you need to do is need to add in an ID so we're going to go ID equals and add those 19 00:01:04,560 --> 00:01:11,420 to apostrophe's there and go change user text. 20 00:01:11,430 --> 00:01:11,920 Okay. 21 00:01:12,240 --> 00:01:14,200 So just go ahead and we'll do that here. 22 00:01:14,220 --> 00:01:21,510 Now what we need to do is what will happen is that once we go ahead and put in some texture we need 23 00:01:21,510 --> 00:01:23,930 to find this ID here. 24 00:01:23,940 --> 00:01:26,890 Now I'm just going to put the go to the javascript here. 25 00:01:27,090 --> 00:01:35,640 Now you might be thinking that we could just add in another document and get Elman ID etc. but we can't 26 00:01:35,640 --> 00:01:37,710 exactly do it like that. 27 00:01:38,220 --> 00:01:40,270 We need to add another variable here. 28 00:01:40,310 --> 00:01:42,000 OK and we're going to just add in a VAR. 29 00:01:42,180 --> 00:01:42,650 OK. 30 00:01:43,560 --> 00:01:46,690 And we're going to call this change 31 00:01:50,290 --> 00:01:53,790 text and then we're going to call this variable 32 00:01:57,620 --> 00:01:58,970 just like this. 33 00:01:58,970 --> 00:02:10,750 And then what we need to do is we're going to go to documents Daut get elements by ID right. 34 00:02:10,790 --> 00:02:19,370 And then what we're going to do is we're going to use this exact same ID which is changes are text and 35 00:02:19,370 --> 00:02:23,900 I was going to copy and paste in there make sure there's no spaces in between. 36 00:02:23,900 --> 00:02:28,130 For example if you see that there is a space in here you definitely do not want that. 37 00:02:28,190 --> 00:02:28,870 OK. 38 00:02:29,360 --> 00:02:32,620 And we'll just go ahead and close that off there. 39 00:02:32,960 --> 00:02:37,370 And the only other thing you need to do is type in Daut value. 40 00:02:37,760 --> 00:02:38,190 OK. 41 00:02:38,480 --> 00:02:45,250 So now change text variable is now equal to whatever we put in there. 42 00:02:45,410 --> 00:02:46,100 OK. 43 00:02:46,490 --> 00:02:53,930 The only thing you need to do is put in where he was equal signs is we need to just type in change text 44 00:02:54,590 --> 00:02:55,540 variable. 45 00:02:55,810 --> 00:02:59,600 And if you want to copy and paste that you're more and walk do you can double click it and you can see 46 00:02:59,600 --> 00:03:02,450 the box shows around that meaning that it does work. 47 00:03:02,720 --> 00:03:05,070 So if you go change the text it doesn't do anything. 48 00:03:05,080 --> 00:03:11,480 But if we do in this case let's change it to a name like awesome and we go change the text. 49 00:03:11,480 --> 00:03:12,170 It changes that. 50 00:03:12,200 --> 00:03:12,740 Awesome. 51 00:03:12,740 --> 00:03:14,010 And we can go to. 52 00:03:14,210 --> 00:03:15,530 Awesome. 53 00:03:16,030 --> 00:03:19,130 Five and you can see it goes to awesome five. 54 00:03:19,130 --> 00:03:26,880 We can say as we change the text just like that and there we go that's all it is. 55 00:03:26,900 --> 00:03:31,910 So what we have to do is we had to set up a variable that took this in here. 56 00:03:31,910 --> 00:03:35,390 Now I'll talk a little bit about this in the next tutorial. 57 00:03:35,390 --> 00:03:39,800 But you'll notice that the variable is inside the function and not outside right. 58 00:03:39,800 --> 00:03:43,050 I'll talk about that in the next the next tutorial so you guys next time.