OK, so let's discuss a little bit.
Keep in mind that our aim is not to learn how to code in, so we're not really interested in all the
details, we just want to see what is it used for and how we can recognize it and also where can we
find it.
So first of all, what is BHB?
Well, as a programming language or also can be considered to be a widely used open source scripting
language, and its main purpose is for web development.
Another interesting thing for us is that, as it says right here, BHP can be embedded into HTML.
What does this mean?
Well, the same way that we can add JavaScript inside of HTML we can do it would be to a simple example,
would be the code that we can see at this page.
As we can see, the cold starts with open mouth pegs, we got some HTML open headers, open tags, open
border tags and inside of the body tag we get a code which is embedded inside of this HTML code.
This is the most simple code, but we can notice what actually distinguishes it and what allows us to
notice that this indeed is a pretty good first of all, it starts with these packs.
We got this arrow pointing to the left, then we got questionmark and then BHB.
This is opening tag for Descript.
Under that comes the code that we write in.
And in this case, there's just a simple echo script that says, Hi, I'm a B script.
After you finish typing all of your code, you simply just closed the tags by typing Questionmark and
Arrow to the right.
And after that, you can simply just continue with your HTML code.
OK, so PCP's used for Web development, same as JavaScript.
It can be included in HTML code, same as JavaScript.
So what is the difference?
Well, JavaScript is used for client side will be used for server side.
The key is that client can really view code that is being run by server, taking into consideration,
of course, that everything is set properly and not configured.
Perhaps this is better said here in this paragraph right here.
So, as it says, what distinguishes BHP from something like client side JavaScript is that the code
is executed on the server generating HTML, which is then sent to the client.
The client would receive the results of running that script, but would not know what the underlying
code was.
You can even configure your Web server to process all your HTML files with BHP, and then there's really
no way that users can tell what you have up your sleeve, meaning that they can figure out what code
you have in.
Another reason why it is good is besides it being available on all major operating systems.
It is good in command line scripting and server side scripting, which you mentioned already.
Server side scripting is the main field for coverage.
For this, we need three different things, and that is we need to have the parser.
We need to have a Web server and a Web browser.
And in this case, to run the code, you can just have the Web server running with the connected installation.
Then you can access the program with a Web browser.
How it exactly runs is explained really good in this image right here or in this diagram, how you want
to call it.
As we can see, these are labeled as steps we go from the device, as it says, user requests, some
website.
It goes to the Apache Web server or any Web server whatsoever.
Then it processes back to the interpreter, which is step number five.
Then it sends back the Apache Web server and then the Web server processes the page and sends it back
to the user.
Now, another thing worth mentioning is that you can make a run without any server or browser, you
could run it with a command line would just be parser and it will still work, OK?
Nonetheless, this is the basic principle behind BHB.
We just mentioned what it was used for.
Where can we find it and how can we recognize what is important to remember?
Well, it's important to remember that is used for server side, it is mainly used for web development
and can be embedded into HTML code and we can see how to do that right here with the simple script.
Everything else that we might need will cover as we go for now, this will be enough.
So that's about it and I will see you guys in the next video.