Placeholder Image

字幕列表 影片播放

  • creating these classes requires equipment and service.

  • Is that cost money?

  • If you appreciate this education, please think about going to Eli the computer guy dot com and offering a one time or monthly recurring donation.

  • Welcome back.

  • As you know, I am Eli the computer guy, and in today's clients, I'm going to show you how to create an HTML form so that you can serve through your records and your my sequel database tables.

  • So before I showed you how to create an HTML form that allows you to insert records into your tables now we're going to use a form so that you can search through those records.

  • Essentially, what we're going to do is we're going to create a form that will allow you to input whatever it is you're looking for that will then pass the information to a PHP script.

  • PHP script will then go.

  • It'll serve through.

  • You're my secret database table, and then you will then a print out of the results that match your query to a basic HTML screen.

  • I will tell you what I'm going to be showing to you today is, uh really is hell.

  • It's gonna be ugly.

  • It's got to be ugly.

  • I would not suggest you, uh, you handing this over to a user.

  • But I do want to show you basically how you're able to use HTML PHP and my sequel to now be able to search through records and then pre able to present a result in a Web browser.

  • So the big concept to keep your eye on today when I'm showing you how to create the HTML form and be able to do the search functionality with PHP is to be looking at the wild car functionality.

  • So normally, when we have been searching through on my sequel database tables, we've been doing, you know, select all from whatever the table is where column name equals something, right when you use equal something.

  • Basically, the only results that are gonna pop up are the results that exactly equal whatever you've plugged in there.

  • So if you type in, let's say Bob on Lee results that hat that are Bob will show up.

  • You won't get Bob as a Bobby as a b o B B Y.

  • You won't get Bobby as a b o b B i e.

  • Right.

  • So that's one of things.

  • When you're thinking about creating a search form, people aren't always sure exactly what they're searching for.

  • So they want to type in.

  • They won't be able to type in a little bit of a snippet and then have any results that match that snippet show up.

  • So again, when you do the normal select all from table name where column name equals, uh, you run into the problem where it will only pop up with the exact match for whatever you've plugged in there.

  • So what we're gonna be using today is wild cards s.

  • We're going to be using the percentage sign while on card.

  • So basically with percentage sign wild card means is anything, any amount and any whatever.

  • Right, s So you see this a lot like with, uh, with asterisks and some coding languages where you can put in asterisks And then again, like anything that matches whatever the middle bit is that will then show up Well, basically, with the percentage signs, you get the same thing.

  • So instead of saying equals so select all from table where you know it's a name equals Bob we're going to do is we're gonna say where name like they're gonna take out the equals, Say, like, and we're gonna We're gonna put the variable But then we're gonna put percent signs on either side.

  • So basically is going to say where um, anything is like we give the variable name.

  • So the variable with any match in front and any match behind and it will print out their results.

  • So with this, when you use a like if I simply put in b o B, then Bob will show up and a Bobby B o B b.

  • Why will show up and b o B b i e will show up, right?

  • So basically anything that has that bob in the middle that will show up One of the examples that will show you is with Jimmy and Timmy.

  • So have Ah, I have some Timmy's and I have a Jimmy right?

  • So I can put in I am and why?

  • And since I had that percent to sign in the beginning, then the results that will pop up is Timmy will pop up and give me will pop up and basically any names with I and why will pop up.

  • So this is one of the values of wild cards, and so is something that you need to be thinking about when you're creating search forms because people will not know exactly what a plug it again.

  • If you think even you're thinking about a name making sure you don't misspell it, making sure you know enough is it to bees or one B?

  • Is it I e.

  • Or is it why things like that?

  • If you could just plug in a little bit of a snippet of whatever word you're looking for, then you can get all the results and then go, Oh yeah, that's the one that I'm looking for.

  • That's the value of wild cards and so wild cards used, like so instead of equal use alike on.

  • Then again, I say we're gonna use a percentage sign the beginning percentage sign of the end, so that will show us.

  • Basically, we give the snippet with any any result that has anything in front of that snippet and any result that has anything behind that snippet that will show up in the results that I'm going to be showing you.

  • There's no real warning warnings for today again, usually when you were dealing with my sequel databases.

  • There's a whole bunch of warnings where you could really, really screw something up.

  • Since we're simply doing a select statement today, there's nothing that you should really be able to destroy.

  • Should should.

  • There's nothing.

  • You should be able to destroy it now with you folks.

  • Who the hell knows what you're going to go?

  • The main thing that I would say for the warning warning today is mainly that you should look at what I'm doing.

  • Look at the demonstrations that I am giving you and then start to play with these these things yourselves again.

  • One of the big problems in the programming world is that people try to do everything paint by numbers.

  • Right.

  • OK, do this and do this and do this and do this.

  • And this gives me a specific thing, right?

  • Well, one of things in the coding world to realize is you're more dealing with things like bricks.

  • I'm basically giving you bricks and then you can build the bricks.

  • You can build whatever you want.

  • Like I show you how to put bricks together.

  • And then you could make a wall or you could make a building or you could make a septic tank right.

  • There's a lot of different things that you could do with bricks.

  • So what I want you to be thinking about today is with the things that I'm showing you to do again.

  • Now that you have the HTML form now, they have appeared to be script.

  • Now they have my secret database and tables start looking at what I'm doing and then start playing around with your own configurations.

  • Create your own tables, create your own, you know, small little projects, see what works.

  • See what doesn't work.

  • Andi think that's one of going to one of the big things that you should take away from today is Don't look at what I'm doing today as an exact model of what you should exactly try to replicate Takeaway.

  • Oh, these are things that I can do and then start playing and seeing what you're able to come up with yourself.

  • So now that we have that, either way, we're gonna go over the computer show.

  • I'm going to show you the demonstrations today.

  • We're actually going to have to demonstrations today.

  • The first is where we're basically going to create a simple search box that will serve through names within the students table that we have been using for previous projects.

  • Us.

  • We have a student's table.

  • The students table has a student name.

  • It has an age, has a gender, has a uniform s o.

  • The first project that we're going to do today is that we're simply going to search through the names and then simply print out the results of that match with whatever name that we have plugged in.

  • The second example that I'm going to show you today is where we're then going to add an option box and tell the search form what column we want to search.

  • So first, the first of the demonstration we're gonna do is all it's gonna do is search through the name.

  • So we're going to hard code the column name, name into the code that we've created and will only serve through the name column.

  • What we're going to be doing for the second project, though, is we're gonna have an option box and that option boxes going to ask.

  • You want to search through the name column?

  • Do you want to search through the age problem.

  • Where do you want to search through the gender call?

  • Right.

  • So I could simply plug in, lets a girl into the search box, then select a gender.

  • And then it was Then it will serve through the gender column.

  • And any gender that matches with girl, it will print that result.

  • Or if I want to do a GE, I will plug in.

  • You know, the eight, let's say 12 into the age call urn to the age where?

  • Into the search box.

  • Then I will select the age column And then any record of that matches 12 for the age that will show up.

  • So those are the two projects that we're going to do it today On With that, let's go over the computer.

  • I can show you how this works.

  • So here we are.

  • My demonstration system.

  • The exact same demonstration system I always use.

  • But if you're new here, I'm using a bunk.

  • You a desktop?

  • 18.4 Lt s again.

  • You should be able to use any who want to desktop.

  • What I'm showing you today will work.

  • I have that running within a virtual machine and virtual box and I have this on my Mac book Pro You bunch of desktop 18.4 I did use something called Task Cell in order to install the entire lamp stack.

  • So packing my sequel and PHP is installed on the system, they are all at their default.

  • I have not configured PHP dot i and I have not modified V hosts.

  • It's all just the standard configuration.

  • The only thing that I've done at all is in the Apache.

  • A root directory.

  • I created a folder called PHP simply to dump all of these PHP example scripts and have them in one place a SW far as the editor that I am using for the code today.

  • I'm simply using G edit.

  • This is just a basic, really crappy editor, the equivalent of text edit on Mac or no pad within Windows again.

  • When I am doing small projects, I like using crappy little text editors because it makes it simple for you folks to realize, Oh, you don't need a fancy I d.

  • You don't need some kind of fancy editor in order to create the scripts that I'm showing you today.

  • So with that, let's go over Aziz always.

  • And take a look at our my sequel database to make sure we know what's going on.

  • There s So you go down to do that a little quick on the things down, the bottom and the surf.

  • You go to terminal that.

  • So basically we had to our terminal right now we're gonna log in and do my sequel Space hyphen.

  • You use her name is Bob.

  • Space hyphen P for the password, that's what.

  • Password supersecret.

  • 123456 And we're going to hit.

  • Enter.

  • We're now in hour.

  • My single database showed data basis just to make sure we know what databases we're dealing with.

  • The database that we care about today is this Class D B s.

  • So then we're going to go into Class D beast.

  • We do use Class B semi colon, Of course.

  • Now, in that database, we're going to show tables So we know what tables that we're dealing with.

  • We take a look and again we've been doing lots of demonstrations.

  • We've lost a lot of tables Table that we care about today is students again.

  • The reason that I go through this every time is when we are writing code, the computer cannot guess at what you mean the computer is not your mommy, right?

  • Your mommy.

  • If you ask your mom for something and it's not quite right, your mom will try to figure out what you mean.

  • Ah, computer is not your butt.

  • If you plug in their own word is just gonna fail, right?

  • So again, simple things like, Is that enable the table name students or is it named students?

  • Right.

  • If you misspell something like a table name, that could be a real problem.

  • S o The table that we care about today, though, is students That's we're gonna be searching through certain use described E S C students verify what the schema of this table looks like on DSO for the scheme of this table.

  • We have name, age, gender and uniforms.

  • So these are the column names.

  • We also have student idea here.

  • Ah, student I d is the primary key and it's the auto increment.

  • Basically, all I use a student i d.

  • For So I have an absolutely unique field for every single record.

  • So even if the names are the same, even the ages of the same, even the sexiest, saying at least a student, I d will be different so they don't run into major problems other than that.

  • Again, we take a look at name that is a text look at age.

  • That's an end like a gender.

  • That's a text and we look at uniform.

  • That's a text today, the fields that I'm going to be dealing with.

  • What I care about is name A and gender past that just to make sure there are records we're going to select all from students.

  • Just see what the records look like semi colon And okay, so we can see that we have got a lot of records in here.

  • It's kind of a mess again.

  • It's kind of, you know, we got Bobbie Sue Lucy.

  • You've got all kinds of different ages.

  • We've got different genders, got different uniforms thing.

  • The main thing that I'm looking here for is that I do have 19 records here, so I have something to play with again.

  • Yeah, you don't want to run into a problem where your search form isn't working because you have no records to Cirque against.

  • So we now all know this is here.

  • So let's go and take a look at the first Make the ml form that we're going to be dealing with S o.

  • I have created a form called surf dot html on if we look here again, this is a very, very, very, very basic 80 mil for so we're going to open up with an HTML tag, then we're going to go to the body.

  • So open up with a body tag.

  • We're then going to go down to the four.

  • So we opened with a form tag.

  • We given an action.

  • That action is then going to pass the information that we collect here to PHP uppercase s so search dot PHP.

  • So whatever information I gather here, this is going to be sent to this particular script.

  • The method is post.

  • So there is post and there's get again.

  • These are simple classes.

  • So we're just gonna use post.

  • You can figure out get layer from that.

  • We're simply going to have one feel we're simply only gonna have one field that field.

  • We're just gonna have a label colt search.

  • The input type is going to be text and in the name so that we can grab the value and turn that into a variable in PHP script.

  • This is how we identify this information.

  • We're going to call it search.

  • We're then going to break below that.

  • We're gonna have an input type of submit.

  • So basically, this is simply going be a submit, but in we're going to close our form, we're gonna close our body and we're gonna close our html If you go over and take a look at what that just physically looks like Goto 1 27.0 point 0.1 forward slash that PHP folder that I talked about before.

  • Forward slash asser a search duh h t m else and enter.

  • And so that's what this looks like, right?

  • So again, we've got a a horribly ugly, simple form.

  • So here is a search, right?

  • So we got certain figure search.

  • Here's a text box.

  • There's a text box.

  • Here's the submit button here, and here's a submit, but so this is simply what this looks like.

  • It is, Yeah, really ugly from that.

  • We're then going to go and take a look at the PHP script.

  • So this is what actually gets interesting.

  • So PHP of our case s for search dot PHP.

  • So we go over here and take a look at this script.

  • This is what we have right on and looks very similar.

  • Thio, what we've had before s so the first thing we're going to do is we're going to open up the PHP script then from that, what we have to do is we have to create a variable and set the value to that variables.

  • We're gonna create a variable called dollar Sign search.

  • So basically, just what the search result ISS we're going to make that equal to and then dollar sign underscore post.

  • And they do single quotation mark here, the single quotation mark and then simply the name.

  • So search.

  • So this right here, this right here that references this So whatever.

  • Whatever the hell name you give this text box you get, make a search, you could call it Billy Bo Bob.

  • I don't care what you call it.

  • Whatever this name is, that has to be this right.

  • That's this is where we create a P eight p variable and we set the value tow whatever the name is from that post.

  • So then we're going to go down and we're going to do our basic connections like we always have.

  • So we have dollar signs, server name, user name and password database.

  • Same thing we've done for the past.

  • Who knows how many classes again?

  • We're connecting to the local host because our my sequel database server is on the exact same machine as the Apache Web server user name and password to the user Name again.

  • At this point, you wanna root level User said that you don't run into permission issues.

  • We have that user named Bob eso Bob.

  • 123456 as a password.

  • Then we have the data base here and again.

  • As I showed you that there's that class D B.

  • Then we have to create the variable for the connection.

  • So the actual connection to the database we're going to make this a new my sequelae.

  • Same thing we've done the past week passes to the value of servant and pass a value of user name past value of password, past value of the database.

  • So we know what we're connecting to close parentheses on semi colon.

  • Then we're gonna go down here is the whole If it fails s o If so, basically we're gonna use the connection.

  • And if there's a connection error So for some reason it failed to go, they will kill the attempt to connect, will print out connection, failed.

  • And then it can Captain eight's the period isn't Captain Ation cabinets on whatever the error is again close parentheses.

  • Close semi colon closed bracket.

  • So if if the connection fails, for some reason, it will spit out an error.

  • If not, it will keep on going, and that's what we care about.

  • So now now we get to the cool new stuff.

  • Now we get to S o.

  • The new thing that we have today is so we have the variable for our sequel statement.

  • So dollar sign, sq, well equals.

  • And then we plug in the sequel statement that we want to use, eh?

  • So what we're going to d'oh is this looks very similar to this select statements.

  • We've been doing the path so we have select so select all so again you could plug in specific column names if you want to.

  • I am using all it just to make life easier for you from.

  • And then we say whatever whatever table we're gonna be selecting from.

  • So we're selecting from the students table.

  • So where and then we put name.

  • Right.

  • So where, uh, the name column.

  • So again, in the database here, you see, uh, students s So we have a name given name table.

  • There are named column there.

  • So where the name column, and then we're going to do, like so instead of, uh, equal we're going to do like, then we do single quotation mark.

  • And then what we're gonna have here is these are the wild cards, right?

  • So here's the percentage sign, and here's a percentage sign.

  • And then within those 2% of signs, we're going to have the value for the variable cirque.

  • So basically, what we're going to do is we're gonna plug in us the value for the variable, whatever.

  • Plugging like Bob B O.

  • B.

  • And then anything that has bobbing.

  • Right.

  • So, Bobby Robert anything Robber Bob Anyways, anything that has Bob will show up, right?

  • And so these are the wild card.

  • So the important thing is is make sure you put the single quotation marks.

  • Then you put the wild card to basically anything with this in the middle will be searched for.

  • Then you close a single quotation mark here and then you close the double quotation marks.

  • So do you remember to close both the quotation marks?

  • And then we do see Michael.

  • So this is the sequel statement that will be using.

  • And again, this is where we use wild cards, aware name, like that's where it plug it in.

  • Then we're gonna come down here.

  • We're going to create a variable result.

  • So dollar sign result in dollar sign result equals connection query.

  • And then whatever the sequel statement ISS, right, So sequel statement This will create the value for results.

  • So if if result, number of rose is greater than zero.

  • So basically, if if when you plug this in, you get more results than zero they weren't going to do is you go through a simple wild while, you know, dollar sign row equals dollar sign result Feck Association so that this is going to go through.

  • It's going to affect the record, turn the record into an array, and then we're going to echo out that array we're going to actually print out on the screen whatever we were gonna print out.

  • So all I'm going to be doing today is I'm going to be printing in the value of name and the array.

  • So dollar sign, row name.

  • So whatever is in the name column that will get printed out, then period can Captain eights.

  • And what I'm simply doing is contaminating a couple of spaces here.

  • So can cat in a couple of spaces with those double quotation marks and can cat me.

  • Then I'm going to print out whatever the value of age is that my new period, a couple of spaces, period.

  • Then I'm going to print out whatever the value of gender is so you can plug in whatever you want here.

  • You all you want the name you could simply print out the name for.

  • He wants the agent simply print out the egg.

  • If you wanted to student idea to name the eight and the uniform, you could print that out.

  • All you have to do in order to print out is you do this dollar sign row, so that's created up here in this wild loop and then whatever did the column.

  • Name is that's what you plug in between the brackets thing we can cabinet on and then we have a break.

  • So this will break the records in the multiple lines else so basically else if there are no records.

  • So here, if the result number of Rose is greater than zero, go through the wild loop else.

  • If there's not just simple, simply echo out zero records, then we close a couple of brackets here and we do we simply close the connection.

  • So dollar sign Khan is the connection that we created here, and then we're going to simply close, and then we are going to close the PHP script.

  • And so that's what we're dealing with.

  • The big thing here they're gonna be dealing with today is this particular sequel Query.

  • We're easing like on then here.

  • This is where we print out all the records that match.

  • Whatever we put into this secret statement here from here, we can then go back, does a little search for that.

  • We have again searched that a team now.

  • So again, what I could do is I can simply type in Let's say, Bob, Then I hit.

  • Submit And so this is C.

  • We see how we get Bobby here.

  • So within the records, we have Bobby, the 12 year old boy.

  • We also have a Bob is a 55 year old boy.

  • We also have a bob with a 12 year old female.

  • So any record with Bob in it showed up eso again.

  • If we go back over and we take a look at the actual my sequel table lets you select.

  • Oh, from, um, students.

  • See what we got here, eh?

  • So let's say we got 10 minutes.

  • So got Tiny's.

  • Let's say, M y right.

  • So let's say we're thinking like, Oh, is it Timmy?

  • Or is it Jimmy?

  • I'm not sure I could go here and again I could do I am.

  • And why?

  • Right?

  • Because I don't know if it's Timmy.

  • I don't know.

  • It was Jimmy.

  • Get the submit query.

  • Okay, so I've got a Timmy eight years old, is a boy.

  • I've got a Jimmy who's 11 years old boy.

  • Oh, it's not.

  • Timmy is Grammy.

  • That's the 11 year old.

  • Then I got some of this other crap here.

  • Timmy is a 23 year old girl.

  • Whatever Basically whatever records are in there, it prints all of this out.

  • So this is a basic, simple certain form for you again.

  • And this allows you to go through and simply search for something like a name like a student's name.

  • So past that.

  • Let's go over and take a look at kind of the improved version of this.

  • And so this is certain with an option box.

  • Eso This is what we're going to do is what we're gonna do is we're gonna be able to plug in a queer, he basically plug in what we're gonna be searching for.

  • But then we get to say, Do we want to search for that in the name column doing a search for that in the age column or doing a search for that Gender column?

  • Maybe I'm just looking for 12 year olds.

  • Or maybe I'm just looking for girls.

  • Take a look at this S O called search option dot html Again, it's a different form.

  • We open up the HTML, we open up the body, we open up the floor here.

  • The action is then going.

  • Be pointed at a script called PHP.

  • Search option, not PHP.

  • So again, remember, when you're doing this, remember to actually modify the action to whatever script you want appointed Thio.

  • I can tell you, with somebody who screws around with a lot of code is really frustrating to sit there and edit the hell out of a particular script and then come up with mistakes because you forgot to reference the right script in the four.

  • So just think so.

  • We're gonna be sending this data to the ph beat search option dot PHP script method, as we have before, is post past that.

  • We have the same search box that we have before us.

  • A search input type equals text.

  • Name equals search.

  • So basically, when we reference this in the PHP script, we're going to grabbing the value.

  • We're gonna be calling you, sir.

  • The next thing that we're gonna have here, though, is we're going to create an option box.

  • We're going to call this column.

  • So basically, what column do we want to be searching from?

  • This is simply gonna print out on screen.

  • We're going to create a select box.

  • We're going to make the name of that column.

  • So when you reference this, we're gonna be referencing the name column.

  • The first option value, the value is gonna be name and then simply print out name on the screen.

  • Option value age friends at eight.

  • On the screening option value gender prints out candor on the screen.

  • Then we're going to close the option box and then we're going to break.

  • Then we're going to put the submit button there were going to close the form here and close the body, and we're gonna close html.

  • So if we go over again, we go to our thing.

  • Would you search option this time, Not HTML.

  • And so this is what this looks like, right?

  • So basically, we got the search box here search as we had before with whatever in there, We have column.

  • So that's this here.

  • And then it defaults the name.

  • So I complete a name or can select age work.

  • It's a left gender and then I can estimate query.

  • So I plug in something here and then this is where I say, what column?

  • I want to search with that.

  • So let's go over to take a look at the PHP Cirque option dot PHP script.

  • So this looks a lot like what we had before.

  • It's almost identical.

  • Three only difference here.

  • There's a couple of differences is up here.

  • When we're creating the variables from that post, we're going to create a dollar sign column Variable.

  • We're going to set that to the value of whatever the name, whatever is in the column name.

  • Right.

  • So get here.

  • So the name column.

  • And so if if if it's set to name, it'll pass name.

  • If it's at the age, you'll pass agents at the gender.

  • Little past agenda, right?

  • So do you remember?

  • So this right here is what prints out on the A team.

  • L scream.

  • Right.

  • So we're looking here upper case in a e upper case, eh?

  • Huh?

  • Age upper case to your gender, right.

  • This pier is what prints on the form.

  • This is what actually gets sent.

  • So if you're going to use this as a specific variable name for something like the column, you want this to be identical to whatever's in your my sequel Data bits, right?

  • So, again, this is important.

  • We think about capitalization.

  • And this is one thing that could screw people up, is what is being displayed to the user doesn't have to be the same as what actually gets passed in the script.

  • So name in the my single database table is all lower case ages all lower case gender is all lower case.

  • So here, when you pass this value, this value here has to be identical to this value here.

  • That makes sense.

  • Then we're gonna go over on here again.

  • We're going to connect to the server as we did before.

  • We're gonna create a connection, as we did before.

  • We're going to set.

  • If the connection fails, as we did before then what we're going to do is we're gonna simply come down here to the sequel statement The Dollar sequel on Basically, it looks identical to what we had before.

  • The only difference is in the wear we simply reference where the value for dollar sign column right.

  • So again for PHP served here.

  • So where name.

  • So we hard coded at the column name.

  • They're all we're doing with this particular script is we're simply saying, whatever the value is of this variable, that's the column that we want to search here then, like, as we did before again we have these wild cards in the front and the back of what we're searching for in the dollar sign certain value, what we're searching that would come down here again.

  • Everything else is the same.

  • So the difference here is where the value for dollar sign column.

  • That's the difference.

  • If we go, then we can start plugging things in.

  • So that's how we do, Bob.

  • Just like we did before.

  • And then we can do name.

  • We submit Query, and so we get the same thing.

  • But we could go back here and let's say we plug in, boy.

  • Then we go down to gender and we get some McQueary Now it prints out all the boy.

  • So Bobby Freddie, Timmy, Jimmy, Bobby, Demi, Mark right?

  • So prints out all the boys.

  • Or we could do a JJ.

  • Let's say we want to know the 12 year olds I goto age.

  • Then I submit query.

  • Now it shows me a 12 year olds.

  • I have a Bobby 12 was a boy, and Bob 12 was a feat, right?

  • I go in, we've got an 11 year olds.

  • Okay, we gotta Jimmy, who's an 11 year old boy and Amanda, who's 11 year old girl, right?

  • And so this gives us a little bit more functionality of our sir forms.

  • And so this starts giving you a way so your users are able to actually go through and be able to do circus within your my sequel database tables.

  • So there you go.

  • Now you know how to create an A T.

  • M l form so that you can search through your my sequel database tables in order to pull up the records that you're looking for.

  • So now you can surf again.

  • You concert based off of age.

  • You could search off of gender.

  • You concert off a name, obviously you can create your own tables, create your own sort forms based off of whatever it is that you care about.

  • But this is something that is actually useful for you.

  • What I would say with the projects that I'm showing you is remember copy paste is your friend.

  • So when the do pulls it down and the notes there is ah, there is all of this code.

  • I would recommend that you copy paste the code and then, like I say, play around with it, see what you're able to d'oh everything that I'm showing you today and many of these classes is very ugly.

  • We're not using CSS.

  • I'm not putting in a lot of formatting or anything like that, because I want you to get the basic concept of HTML PHP and my sequel without getting into the weeds.

  • So one of things to be thinking about is again.

  • How?

  • How can you make those results prettier?

  • How can you make those results more useful again?

  • One of the big problems with the technical people is that they create products that that work, that function function is probably the better.

  • Were they create products that function but that are just horrible to you?

  • It's horrible to use.

  • So again, like when you're thinking about printing out a record, you can simply print out text like I did on different lines.

  • But as you can see, it's not spaced very well.

  • It's kind of hard to read, so something you can think about is okay, well, maybe when I print this out, also add the coding Thio to create a table in HTML, and if you're going to do that, maybe add some color.

  • Maybe King fought size, you know, play around with it a little bit.

  • So not only are you providing the technical, the functional results to the end user, but you're actually providing the results in a way that is easy for the end user to understand again, as always, I have some old timers out there that are Campbell, a main at the way that I'm showing you how Thio create these little PHP scripts and interact with my sequel database is not a good way to create a code for production environment.

  • And as I will say again and again, I agree.

  • What I am showing you today has piss poor secured again, doesn't have very good formatting what I'm showing you.

  • I would not put into a production environment.

  • But this shows you how to start doing these things.

  • And then once you understand how easy it is, then you can start adding security again.

  • You can start looking at creating privileges for user accounts, using the proper proper privileges and trying to tighten everything down to actually make it more secure.

  • So I do want to say what I'm showing you these classes.

  • I would not I would not duct tape this together and throw it out of the production environment.

  • This is horribly vulnerable from a security standpoint, but is useful to show you how this works.

  • And then once you feel comfortable here, then you can start tightening things down and actually making the security, uh, worthwhile.

  • So as always, I enjoy doing this class and look forward to see what the next one apparently the type of content you just saw is not what Susan W.

  • Wants for the future of YouTube.

  • This means that recommendations by YouTube to this channel have dropped massively, and views are becoming a comically small I hate to ask.

  • I used to say I would never ask, but if you could subscribe like common and most importantly, share the videos that you appreciate, that may help slow the death of this channel.

creating these classes requires equipment and service.

字幕與單字

單字即點即查 點擊單字可以查詢單字解釋

B1 中級

MySQL - 使用HTML和PHP的搜索表單 (MySQL - SEARCH Form with HTML and PHP)

  • 2 0
    林宜悉 發佈於 2021 年 01 月 14 日
影片單字