Wednesday, 4 April 2018

Relational Tables lecture -15


hey as what's going on is clever taking and in this very we're going to be
learning how to data into my the skill database which has many to many
relational tables so this is what the basic syntax(Dallas Website Development) it looks like for
inserting so like innovating and doing data into my school tables so for the
insert we have answered into keywords followed by a table name and said the
around brackets who have columns spirit in common than we have a
keyboard called values and inside the round break we have values separated
by Hama and make sure to always in close your values into single quotes when
writing the code and right so the valley one is going to go and say call
them one and valley to is going to go and say column to and you can have as
many columns of valleys as you one next up his select and we have so I could
followed by a star if you want us like all the record from the so we have a
work called from a table named keyword was and then the column name equals
the value in closing single quotes and you can also have as many columns if you
want by and in then with a and keyword and then following that by color
named eagles value in closing the single quotes next what we have an update
table myself cured and whatever called me you want to have [UM] so you set
the valley of the column named equal to a new value in a cause that in a single
clothes and you can also have as many cans as you want by separating them by
common so you full of that by cannot a column and I'm not a value and then
you have where she worried and column and he calls value in a closing single
close to they share my school knows which exact columns to try to update how
do we have the elite delete from table name were column equals value and if
you in this part here so you could just right do it from a table is going to
india we all the records from your table so that's basically my ask also index
and that's all we're going to need for this video so what we're going to be
doing here is we're going to be inserting data which we're going to be
scraping from met movie data was [NOISE] calm and we're going to be in
sitting all the data in our database which we have created in the previous
video with many to many relational tables in it now the kind of a tricky
part is going to be inserting the data inside of these many to many with
tables and the way we're going to be doing this is inserting the movie I'd
as you can see all these three tables have movies and it also has directors
an idea which corresponds to the main primary key of the people's which movies
is linked to so for the directors has directors stars has starred idea and
join us have started our genres and the way the tricky part is knowing which

the movie is associated which you with which director and what movies associated
with a star and which movie associated with words john around and for that
we're going to be using a special function I cold my school I insert idea
which gets the last key of the movie which has been inserted into the
database so that how are we going to know which movie is associated with
which I'd because we're going to be getting the movie good which has been
inserted last so well if you guys don't have this do have just gone ahead and
go to quite a common click on this article here and I've been it I ask you
well source code down here had just copied the whole [SMACK] and you can go to
the stream I am in and one or databases go out to create the data was called
movies had created and then go to ask you well and just space the whole thing
there and quick so that way all the tables will be created and if you go to
movies database so you can see that all the tables are there so you're going
to need that and also going I need them the bees a scrape in the script
which we've created any other you know as well if you don't have that no
problem go to clay we're taking calm once again and click on this article
called was creating using page and I've included all the source code there
so just copy this whole source code and I become and to you pace this code
inside and you feel called scrape on the score I and be that PHP and later
on you're going to be able to include in your other file which we're going
to be used to insert data into my school database and when you just be
cared this so the first of all I want to show you guys what we're going to
be a

Andre expressions php lecture- 14

hey guys were going on is to keep and in this lecture, we're going to be using a
regular expressions as part of a stem out just head up this Lecture is going
to be more advanced so i'm going to be moving a lot faster than you visual
so go and review this rage expressions(Dallas Website Development) cheese seater which my other very Andre expressions if you're not very fa miliar whether before watching this
video i was going had and get started so in this video we're going to be an
out I am a website which is an anomaly database and it's going to be using a
website called as one one dotcom to how struggle expressions against the
strength to make sure where matching them correctly and i've also decided to
have all the code to because otherwise would take many hours to show this
video so just to keep things short time was going to be explaining what
always called means so the first thing i like to do when matching a constant
from a website like this is to identify does sir reach stream from wish to
to match the content from so the sea al here is just showing a bunch of
movies that were released in the year or two thousand and i'm starting my
surgeon page one so you have all these elements like the title the year in
description director and stars and boats and draws and the image name so
we're going to be imagine all this content now the problem is here i'm going
to be using brain which all function which means we're going to be match and
all the elements at the same time now if i go to the later page for example
page seventy six is going to be a miss in a lot of that content so that
makes it a little bit more tricky because we can just match all the elements
individually we're going to have to measure block of elements for example
here we're going to have to match the moving on time genre and the eye
mediating at the same time and and check if any of those elements or empty
and if they are which is going to set the area value to an empty string so
let's look at the code now and all this is going to make sense hopefully so
first thing i'm doing is i'm loading up their ~~~~~~~ seventy six of the
surgeries walls and a story everything inside the result variable i'm also
creating a new era do these make and i'm just making in a [NOISE] so the
first matches i mention a movie title so this is a regular expression here
and i'm going to go ahead and piece that i go expression inside the right so
I aging and die and a search for this little string here inside of the
search results for our page source going to go a place source and I'm
going to search for that so since we're all in the last be here [COUGH]
seventy say this and who are matching this part of the regime it's shown

fifty results which means all the movies the photo movies that are showing
up on the page is you can see is showing up fifty results and this his old
has been mashed fifty times so that means it's a reliable way to match the
an actual title so that's why using this street this regen expression so if i
the place to actually i'm out here you can see that it's in fact capturing
there's a group one which means is going to store inside of our under a tree
one and his capture in the actual bulli tidal so you can see you're under a
the regular expression I have the little text then instead of the tt and this
the number I have a dog star question mark which means is just going to capture
anything so anything that's there is going to capture it at the numbers
going to change that's why have used the regular expression in this way
then I have the regular little text and then I was that you're flying break
here because there is a new line and then up captures everything that's
between the tags inside the basically using the same thing as a dot
starting question mark and captured it using them around records and that
creates the capture of the movie title ~~~~~~~ so another woman have made
sure that they're at your expression of works was actually go had a great are
movies named just to see that the fact matching all the titles and in fact
it is there's fourteen I know this is the ark stars with zero so there's so
elements and it's matching all the titles so now we're ready to Milan to the
next one which is a year and here's a Reagan expression for the year I'm
going to copy that inside the relics engine

php regular expressions (Lecture- 13)


what's going on guys is quick and in this lecture, we're going to learn a PHP
regular expressions(Dallas website Development)  so this is eighty cheated afraid here and I'm going to refer to it about this video and if you guys want a dollar a full resolution
of this image I have an included bank and inscriptions of this Lecture so if
you like to download to go and so so first of all live let's go to a website
called one on one and this is an also website that I would just discover
where you can practice regular expressions and rail expressions you can
think of them as basically wildcards on steroids so there are just patterns
to imagine a text and it's really useful if you're a web jeweler in the
one so I've matched some content on websites you can easily do cell with
regular expressions as well as mentioned any other content and also so for
the test or in I've included this pestering and the description of this
video as well and this is just a bunch of so a text that I've found where we
can you use the sex to practice using regular expressions on so I'm just
going to refer to this key cheat we're going to go over some of these these
quantifies care to classes groups and the ranges medicare is as well as
flags so we're going to go over all this just of and I'm going to explain
what most of these things mean so it was go had just started here so the man
which is any characters so if we simply could dot here it's going to match
all the characters on here and if I put star is going to which all the
things together so basically what the start is just to zero or more so in
this case if we put any character full followed by a zero and more this is
something that matches basically all the content so if you have a web said
or the other content placing a dot and a star heart will match anything and
he's probably they see something like this which is a wildcard dot and a
star followed by the for example when if I open up in north at here and you
go flying low then you get a sea down here and the types documents this is
the exactly the as the gray expression that's down here which is a start and
they die followed by the tea which means it's going to match [UH] files
within the text and there's another one of the years which basically says
match any extension at all and the star [UM] is exactly what that means
match anything so all right so that's how you match anything and let's see
here so please just means one there are more so that has to be something to
be matched where he starts you can match nothing or more that the question
mark is when things get a little interesting ok soul let me show you the
difference between the two so if I wanted to match these strong tags like


for example, if you have that if you have the constant website and for some
the reason you want a national HTML takes here is do you might do you might want
to do this right so who have this is what is called this is called the
greedy quantify fire because what will do here is you'll start with their
little [SMACK] angle bracket here and then you what you do when is basically
you're expecting to match all the content and then and then basically you
try to match this strong tack here but instead, this thing is greedy so is
going to go he had and match all the thing until it sees the adding angle
bracket here and that's what it's called green tea because they will match
will consume all the content in between the heavy this single bracket and
the single bracket here and if you wanted to make it a lazy your credit you
simply put a question mark your so now you can see that is matching the
asian my legs like we wanted them to and it's also doing that here so that's
the difference between greedy and deal

php variable hendley in function (Lecture -12)


hey guys equipment taking and in this Lecture, we're going to cover each the
data tapes and variable Hendley in function so and pitch be variable that it
is can be broken down three different categories scale or compose in a
special [NOISE] so the scale or as a single unit of the data and this
enclosed variables like the string which is text entire which is a whole number
flowed which is a fractional (Dallas Website Development)number and bully in which is a zero or a one
and it could also be represented as truth for one hour of false for a zero
next, we got composite which is an error an object and the or a basically
holds multiple values like you see here separate it from the common and the
object refers to the instance of the class so if we have a class claimed
the movie, for example, we can then say object because of your key and then the class
and that will create the object instance of that class so that's how we
create an object data type finally have a special and under special we have
a no which is basically means nothing or no valley at all and I'm not a one
is a resource which can hold special values like database connections open
files etc so these are the most common genotypes you get to encounter and teach
I now let's actually create some of these variables and that we can play
around with them so the first one time get any flying is a string variable
and so this is just going to be information about a matrix smelly I think
it's a good way to demonstrate all kinds of different [a COUGH] that a types
and teach me so this one is it going to flow and we find some was true
[UH] ~~~~~~~ and they're not going to create a more on and this one is going
to be associative or a and it's going to have actor names and the rules
the played in the movie and so I was going to put a couple of game and year
more beers for the end the that's enough so that is going to be our
associative and then today is going to be a rate that I'm going to create a
classroom you leave I create an object main tricks use and they knew the keyword
followed by the class lane which is a movie and that's can create the object
the instance of the class and it is defined in our world ~~~~~~~ and finally
[SMACK] is defined a resource and this one is going to refer to the open
file [a COUGH] going to specify the directory where this text while is located
can be any x files so and so this one is going to become a resource now
let's go ahead and covers some of the variable handling functions and the
reason I want to show you this is because there's you want to have variable
functions or variable having functions and Picchu which give you all kinds
of the information about data types and other information about the

variables and as you can see the first ones to get the type and it does exactly
what it says I guess I did a type of the variable now we have is said which
checks if the variable has been initializing on said destroys variable and
then we can just down well these this little teach either table here and
just check out all these other variables and play around with audio variables
that we have just defined but I'm going to create a loop now and I'm going
to who's get die variable to get the information about all the variables
that we have just created to get the data type but before I do that I'm
actually going to define a new very people and is going to hold all these
variables in it are using it rains so I'm going to find a variable and data
and then I'm going to say a rape and I'm just going to put all these
variable names inside of this range you now we're going to use a for loop
to look through all these variables inside of the data rate and I'm going to
use a get type function today to type ii of these variables of a soulless
creative for loop

php Lecture -11(Loop)


hey guys what's going out and square ticking and in this lecture, we're going
to learn about the beach for if loop(Dallas Website Development) the for each loop is used to look through and associate embrace so inside the break is here we have our so she to a
follow that by the going as and then we have our Niki which we can start
inside of a key variable full so that by the rocket operator and then the
risky value which we can story people called value now the key and value
variables can be named anything as long as you remember that this one refers
to the and that this one refers to the risk of out for you and just to
review this is what they're so she to a very looks like the key made with
refer to them in this example and the value variable would refer to the key


 the value which is twenty-three so that's the syntax of the for each flip now
the loop is going to end when the final key valley Paris it's so in our
the example here one german forty-two key valley there has been reached the loop
is going to end [NOISE] that's it for the syntax now let me show you a
a practical example I'm going to go ahead and create a new era here and of
animals and always going to be is by having animal names along with this
sounds those animal meaning those the more make so I'm going to create from
bad as [UM] ~~~~~~~ [COUGH] lawyers [UM] of ads some biennials care [COUGH]
health and hunger and culture [SMACK] was streamed the animal named here is
the key and the area value is the sound that this animal makes so I'm going
to go ahead and looked through the animals a now [UH] if you can see I made
my variables name and sound because it makes sense inside of our animals we
will have the animal name and this is what the names are referring to its
referring to their the key of the area and the sound is your for into the
valley of the rain so if I these two here and I use a space that can cat age
you together and then at the and I'm going to use the art make it look nice
or this is exactly was going to print out they're going to print out the
animal name and then space and the sound which the animal makes so as you
can see here there or is expected we're looking through their so she too
marry and it springs now at the art and the arrow value now I'm an all turn
as a way to write this would be as follows you can just use the associate
of a raw name and since who have access to the key this whole give us the
valley of the right and so now we have all the valley is not a way to write
this is to completely avoid this part and if we wanted to just print out the
arrow values who can do so in this way as well so this the same exact thing
as before so that's it for this example and now I want to show you something

else I want to show you how to money my area valleys by a reference so for
an example he found that renamed numbers and was going to keep the short and
put find numbers and year and then I looked through this area numbers are in
the short version because only need values were going to print out this radio
the most and the numbers if all the name and so right now has just printing
out there a and we have a key we have a value have a key you have a valley
so you can see that the all the valley as one two three four five now if we
wanted to directly modify those valleys here's what we can do and this is
called dietary valleys by the reference he would simply put the emperor sense
and from the air key and then we can say something like numbers equals i
mean number eagles I'm very times to and that would modify the three
a valley is so now all the all the valleys inside of the area would be doubled
so if I print out the area down here now

Tuesday, 3 April 2018

php -expression ( Lecture-10 )


hey guys what's going on is clever sticky and in this Lecture, we're going to
learn about this piece which statement [NOISE] so this is the basics in
texts of the switch statement to have a cure switch followed by the expression
inside the around records and between the curly brackets we have here it's
the case followed by the valley to enter Collins and break for by the semicolon
so what this means is if the expression of valleys to zero so then we want to
following cold dessicated and then we end the execution with a cure break if
we don't use the cured break after code (Dallas Website Development) then all the following cases
where also be evaluating it and the code will also be executed and I'll give
you an example of how that works a little bit later now the default cured it
will be executed if none of the other this matches so if our expression
will value to for example five then that code goal be executed so it is i
wanted to use break if you don't want all the following cases to be as luck
and the switch statement can be written and an alternative form like so so
instead of early brackets, we can use a column and instead of the ending
currently bracket we can also use and switch followed by the semicolon so
the switch statements index for you and now let's go ahead and I create a
little script to see how warps and practice [NOISE] so I'm just going to
create and our folk animals and I'm just going to put three animals and it
can a dog and duck and then I'm going to use the switch statement and for
the expression I'm going to put in our [a COUGH] and then I'm going to use
area and the or a trend function to pick out a random key from there and so
at this point king randomly take out cad Dugard duck and first the value
which we're going to get so we're going to write case I had colony coal now
so I'm just going to put in this sounds with the animals will make in for
cases which are a dog and dog ok for the documenting put echo with and final
we can forget to break that and place duck from enough with a is the break
and that's a basic program and I'm going to go ahead and running no and i
refreshed the page keeps refreshing and so as you can see randomly puts out
different animals sounds based on the can a kind of random art and value
which has been text out from the rain so that's a basic as an example of the
switch statement now let me show you a for example if we added the default
you're here and we get to say something like any model why did around for your
life so the good idea to run for your life we haven't an animal and here i
would put something like wants [UM] or and now if-if not of the other cases
had the magic so if it's not a and it's not a dog duck it's not a dog then


the default cases executed which are monster, in that case, I know animal
detected around for your life his executed and if we keep a hidden random is
you can see it keeps selecting at once in a while randomly so that's how the
default works and so now (Dallas Website Development)I want to show you an example if we simply don't
use breaks and it's going to give you I'm going to pick create a very boy
named speed I'm going to save sixty-five and so this is going to be like a
car example where we're going to be speeding so I'm going to see the switch
speeding and then I am I going to type all of that I have all these taped up
already but basically is going to give you a different message based on what
kind of same speed you have here so in a case in sixty-five and the age which
is the valley right now we're going to say you're going the speed limit
response.

php ( variable leacture-7)

what's up everybody this is quivered taking and this we're going to learn
about beach the sessions what our peach piece sessions well it's a way to
information across multiple pages and in phd to this information in sessions
is stored inside variable named on their score session it's a global
variable so by cookies where the information has stored on the users
computer and and text file sessions in sessions that information is stored
inside a global variable(Dallas Website Development) so i for their here named sessions and i'm going to
create a new file and i'm going to name it one that ph the way we start
session and b c use using a function sessions right at this point the global
variable on the core session becomes available so we can now set our session
valley is so we can today for example and you can treat this session you can
think of the session global era global variable has an era so we can said
the new named gene called username and said into a value and also set of
some other one [COUGH] what i'm going to do here in named role and at this
point let me just use my function to print out the iran and a better way and
i'm going to say pre are session to print out the rate and i'm going to open
it and as you can see the being variable rate has been printed out and
everything is working is expected now we can also say on this which session
variables had been set because the be hard to go and so on this page we're
setting our session variables now in order for us to check at the session is
working on other pages i'm going to create an a page and the gang came into
and i knew that each and i'm going to create html link i think into that
page the that with two of the game and on this page want every page you have
to their you're going to be access in your session variables and you also
have to use the function stations starred otherwise you're not going to have
access to that global session variable and at this and the information is
going to be available to us on this page as well so contest that out by
printing out there session or a and i'm going to go ahead and run one the
page me now which is the first page where we're setting that sessions
variables section very well have been set and if i got to to that pc as you
can see that session keys and values are still available because well what
we have successfully set the session and now we're access in them on the
second page so that how sessions work and that's a simple is that now we can
also modify session variables for example i can save session his name
because these a reality i can say said antinori username and then we can
print recession again that's what happens and i'm going to go ahead and 
 

open up one that they speak with on the link and now the you can see our original
values as well as the new valley so that's how you might have fire session
variables easy and let's see here lastly if you want to and the session you
use a function called session this underscore destroyed at this point our
social bees troy so if i around this file we need to that says can see this
session keys are not available in a more because we have destroyed [SMACK]
and and if i go back to one which is where we are setting our session
variables and then got a page too then all of our tease valleys have become
available(Dallas Website Development) so by using session destroy you're destroyed the session and raise
the session the re as well so that's how sessions work if you guys found
this useful please like sharon saw scribe and i'll see next time clever
taking out

Php Keys (Lecture -8)


hey guys what's going on is clever taking and then this lecture we're going to
we Interpol nation what is inter palatial well it's a way to accessories
and they methods and properties inside double quilt so I broke them down in
for categories first as a preferred way then there are valid alternatives then
there's the only way and finally, there we're are only in valid ways to
access properties etc so let's go over the preferred method first so if you
haven't made with a single so she ate off a key and there are no spaces in that
the associated key you must think to close the whole thing in early brackets now
next, if you have just in numeric or a with a new very key then you don't
need any early back it's for that and that only applied to a single a single
dimensionally erase now this is a really cool one here you have an object
and he too acts as a property name you don't need any curly back and this is
the one that I'd just found out about as I was making this Lecture I thought
that you had two enclosed those literally dragons before and as it turns out
you don't have to so this is just I'm the really clean way of vaccine property
themes of your objects so next there's a valid alternative so this one i
also didn't know about so if you have associative things so dimensionally
china the associative clean name you actually don't have to inclose it in
the quotes in the single calls in this case and php man you know all that's
what they say you don't have to in close that in any quotes however you can
get a little messy later on if you try to print the south outside of double
codes(Dallas Website Development) it's not me we're also if you have a space in your associated key
that's also not going to work out so I still prefer the preferred method off
ink using the associate a key inside the early brackets inside the double
codes when you haven't single associative or a key so if you have a new
meraki you can also in close it in Kuril brackets but these early brackets
optional so I prefer this way here and also undervalued alternatives we have
our property names you can also egos him and early Braque is but they're
also optional as I've just found out so the third is the only way you can
the access he can access the properties and in this case, we're trying to
access object method and you can now access object method if seeing close it
in curly brackets however, that's not true for regular functions as you can
see down here I've at contaminated the function with the dogs with the
contaminate operators so when it comes to object methods you can in clothes
that and currently brackets but we need it when it comes to functions you
must compact undated and looked up we got an associated a single dimensional


with space which you must in closing currency brackets and for any
multidimensional erase just remember that we have to enclose all multi-touch
secondly inherently brackets whether there are numeric or associative so
[UM] names you must can cattle eight and cars and you've also most can
captain eight Constance you can just put them inside the box with currently
brackets or in any other way so invalid methods here you can see he said me
live printed the a with an associate keep the devil course which is
not going to work you're going to get an error he up next as a constant
enclosed in the current brackets which are not going to work as well next
as a function (Dalllas Website Development)name and clothes and thirdly brackets which is also I'm going
to work because you can see the text high lotteries interpret the values
as just strings next that we got an object property which is enclosed in
a single curly bracket that's invalid next we have a method called which is
not in clothes and early brackets, that's not going to as opposed to math
properties next so we got a multidimensional or a which is not a clothes
and cold brackets lesson are going to work and the next we got which is we
got which is a multidimensional rate there has a three key followed by then
niemira key which is a closed incurably brackets now that that is a tricky
one because you can use a single dimensionally without enclosed and the the
in single calls but one

php 6- lecture ( Classes)

 I was going on its clever taking and in this Lecture, we're going to
learn about beach gases and objects first of all this review the six of
classes an object real quick so well by in the class using a class cured
followed by the class name and inside the currently back this we have
properties and methods of the class so properties are just in other words for
variables and that's what we call properties is what we call variables
inside the class and methods is what we call functions and so the glass so
you can think of a class as just the collection of property these and
methods and that's all it is and if we wanted to access our property inside
the glass we would use a keyboard this followed by the object operating
an operator also known as a dark I'm just going to call(Dallas Website Development) 
the radar from now and you do the same thing you for as if you wanted to access 
the method names well now I would say to a glass as we actually instead she the object
using the new you're followed by our last name and at this point when we do
this the object of the class has been instantiated and that means the object
is going to inherit or basically obtain all the methods and properties of
that class so we can use the hard operator again earlier the object
operated to access all those properties and methods with the object so let's
move on and let's let me define a simple class called and again glass can
gained early brackets now inside the glass I'm going to find a bunch of
properties and just one method so, first of all, every game is going to have a
price every game going to have a name every get games going to have a photo
array covered picture and I'm also going to define the variable in directory or
the deer and I'm going to have specified to fold value were and this is a
you're acting area where all I gained pictures are going to be lucky had its
own at this point to have a valley class was just define on that to function
are not a function and method and this method is going to print game
information to the screen so right now at this point it doesn't really do
anything but let me just show you how to instead she at the objects so if i
had ~~~~~~~ had [UM] invariable and I said new gained at this point out the
game would become the game variable will become an object also gain class
a theme is the object typed game clouds and second starts said some of this
properties to the actual game so I can say something like gained object
the operator named he calls by a shark and since big game the are price equals
fourteen ninety-nine big gained dark photo equals and this is the jay bag
name of the photo which is inside that games [UM] or and so here I'm just

giving you an example of how you would set these properties outside the
class for the actual objects so inside the print function I can now see and
this named occur this price and occurred this so to [SMACK] this directory
first and then for tough ok at this point let's see what happens here if i
called it method outside the class game dark crane game should out but some
information (Dallas Website Development) is so printed out all that information but lets me just define a
constant then you really defined called the are and it's just going to have
an again it now for the constants it's a little different we don't use that
this keyword and a dark object operator instead that we do this we do cells.

Raise Our Common Feature (Leacture -5)

They raise our common feature: and many programming languages raise are going
to be extremely useful for helping us to keep information the organized so
what is a right under a isn't ordered in nature and next collection of
objects that's a fancy way of saying that we can take objects like strings
and injury and put them into a group and then keep their position in that
the group in the same order so that we can refer to those objects by their
positions (Dallas Website Development) we can tell the or a give me back the first subject to give me the
fifth object and so on because the objects are going to be indexed according
to what position they hold in the or a when the way to think about it
they're like was expanding follow folders that you can buy a preacher bills
and you might put your electric bills on the first pocket on your phone
bills in the second pocket mortgage payments of [UM] and so on you have a
preset order and you can put things in pockets and take them out again put



this paper into the third pocket show me the paper that's in the fifth
pocket that's the way that raises work now there's no limits to how many
pockets eureka and have at least and in that, you're going to eat about and a
pocket contain anything that is variable can take a string a number
even another right, in fact, a pocket can be just playing empty and then they
can be assigned to a variable which makes it easy for us to reference a
large collection of information by using a single simple variable ok let's
try and example pulls will open up basic got female to save as and with
called this arrays that peach pile change the title the rays and let's
create our first the tags here now the first and I'm going to create I'm
going to sound to the variable numbers now the way that you finding or a is
wide open parentheses closed parentheses and then said we now have defined
an empty or a and assigned to choose numbers there are no objects inside this
or it's just empty we can put a series of objects in or a hand separate
them by using a, for example, an in numbers poorer common they come up fifteen
common sixteenth [SMACK] twenty-three come and forty to so now I have an
an array consists of numbers and those numbers are always going to stay in the
order that I put them there they can stay in that exact order and that
the way I can refer to them by position when I and to get them back out so
let's try that let's see how we retrieve something from I'll use though
we're going to reference the label numbers because that's what's pointing
to our right from is it and then we're going to use square brackets and
inside these square brackets, we're going to provide the index that we wanted

to return in this case the index will be the fashion that's return what's in
position one but are some of at the end and let's bring them up in our
browser and take a look go back to fire fox and instead of floats that
spring of a race so there it is a return an object to us and the object that
I returned was eight now to wait a minute if you go back and you look wait
is what we would have expected was in the second pocket and that brings up a
a very important point about a raise the just always keep in mind a raise our
numbers starting from zero the first pocket is in next to zero the second
a pocket is indexed isn't it will take some getting used to you have a working
with the rains before but that's how raised work in almost every single
programming like we're not just mph so if we changed our index to be zero
and then we go back and we reload our page will get back the first time
which is for so the first time from his indexed with zero you really want my
sure you drill this idea into your head the first pocket in their a the
first item under the first value has always going to be referred to by using
the in next zero and they said in Iraq and contain lots of different types
of objects so, for example, we can have a mixed type object we'll call it
mixed and inside there will have an array and in that are a let's put the
number six the word fox followed by the word dog followed by another a then
another day will put text and y and z a so you see how that works it doesn't
matter what kind of objects we put in there can be in voters can be strings
that can even the other [UH] pennies valid type of Ph.D. can go(Dallas Website Development)
inside and solet's now go back one of those values let's to go from mixed and let's ask
it for what's in number two but some be our tanks and here and just a clean
this up a bit but one of as well and it also houses it before we go back
and below the page for what is in pocket number three now, we know what
number two should be Riker's we know that they start coming at zero so you
can go down the numbers and say zero one too and figure out what's going to
be in the second position the second index let's bring that up in the
browser and take a look and see if you were right and it return the dog to us
now notice here we've got to notice a rate a string conversion is what's
happening and it returns to us or a.

Monday, 2 April 2018

php 4- lecture (Peachpie )

Peachpie:(DevDigs/Dallas website Development)

raising more detail well now here's a quick overview of this
phrase peace be we define a new miracle using victoria day and then inside
the around like yes we have our valleys and the mary these are automatically
created for us when we do china numerically and if we wanted to create in
associate a very we use the same cure day and then inside the round records
was specify what the key names or in the single double quotes and then we
use the rocket and probably that by the value so let's go ahead and start
coating so here's what we're going to be creating i'm going to be we're
going to be a reading these files and images inside a new miracle a and
peachpie and then we all will create a associative parade out of it and then
finally we're going to that we're going to create a nice email table out of
the associated my is going to look something like ~~~~~~~ so it's pretty
nice looking html table and we're going to i wish that with piece bees right
the start coding so first of all again put up the she takes here so my the
directory of the movies where those files are located is inside the movies
folder so i'm going to specify their director you've within variable and i'm
going to use a function called sand area which is [UM] this functions can
there and it's going to read the directory and is going to put all the files
and that the or a so here's what is going to look like if we print out that
follows or raise the clothes that and i'm also get have used the function
called down we are that have to find earlier in an the video so we can print
out the pre tags automatically so once we use a scanned their function
here's what they are raise going to look like as you can see it has and read
all the file names into a and and it's created a numeric or a out of it now
let's go ahead and remove those dots in the first two keys of the array and
for that we can use a function called did so we're going to save files which
is our age and then from did and i'm going to specify the or a which is our
exists in area and then for the second one i'm going to specify not a and
the values so what the every underscored dysfunction does is that compares
that too js together compares the first to which is files and the second one
that have created here and it returns and the way which is going to we've
which is going to have all the values but the ones that are specified in a
second they right so as you can see have printed here and it's the dots are
no longer there so as you can see also it it's not starting from from he's
zero and one instead of starting from two and before we start looking

through this i want to reset the keys and for that isn't that a function
cold i'm going to say file files equals or a values and in files so that
will reset the count back to zero and so the function is for as you can see
it's starting from zero now and now we already to work with this new mary
crane some is going to comment out all these printing functions and what i'm
going to do here is i'm going to create another very cold movies and what is
going to look through this new mary called files with all was fine names and
we're going to put it all inside this movies and i'm going to create a
associate me and and you'll be a lot easier to work with once we started
creating our asian email tables so was going to create a loop and for a loop
and to say and files on what the count function does is just counts the fire
a returns how many elements or inside their age so that we can and now i
went to end a loop once the
Written by Devdigs (Dallas Website Development)

php 3- lecture (php functions)

php functions :( Devdigs/ Dallas Website Development)

in more detail now just a quick review we find a function using
the constrict function followed by the name inside the round brackets we
have functions arguments separated by a common and you can think of
arguments as future place holders for the actual values and when we call a
function we used a function again the round brackets and inside we have the
parameters every by the common and the letters and the actual values for the
arguments so these parameters are going to be past over to the arguments and
inside functions code they're going to be modified or printed out or
whatever right it's so let's go ahead and so we're some function basics here
first of all going in this constant that i always define called h similar to
be and then let's create a function named multiplied and always going to do
is to by two numbers together a very very basic function just to illustrate
the next and i'm going to use a for return to return to values want times
too so so the return does is it basically you can for the return as a
valleys so if i call this function here and used to values five and six
nothing will happen in the output because because the valley is returning as
being returned back to as a variable basically so i would need to occur the
valley out and now you can see thirty as showing up here now if i wanted to
directly print devalue to the screen we can do sold by just using i go
inside the function and save echo one times tube and now if i use multiply
print ~~~~~~~ five's and turn this value as you can see ~~~~~~~ being
printed out direct directly to the screen without me using aqua keyword


because i already used that in the function so that just a little
distinction between the return and print in the valleys directly highlights
let's go had a move on here this so let's define a function that will print
some basic information about a person and inside the functions arguments you
can actually specify what kind of a data type you're going to include so if
i specified here this functions first parameter is only going to take today
as as its value so these that print our function here so if i use this
function here print and i specified something like string here i would get
to catch iqbal saddle fatal are argument one past to printing from must be
of type a string given so so if i did a raw now names wrote a key now i have
my arabian printed out so you can use what do they called basically they're
called type declarations so you can specifying what kind of a type the
functions argument is going to take in as a parameter and that's how you

that's how you do that you can also have some [UM] values here like for
example let me just go i had defined in our with some of my information
might in front called might inferred and i'm just going to have my basic
information and there it's like named [COUGH] michael named age ~~~~~~~ when
the gender ~~~~~~~ and the health ~~~~~~~ should be no for new now i'm just
going to insert this era inside a function just to make sure is still bring
printed out that's cool now i'm let's go ahead and

Written by Devdigs (Dallas Website Development)

php 2- lecture( peachy PHP bot framework)

peachy PHP bot framework(Dallas Website Development)

those are more detail just a quick a radio you variable names
must start with a dollar same followed by the variable name and a very will
name start with the letter or underscores has signed a value to the very
well using the equal operator and we end this state have to semi columns(Dallas Website Development)variable names and the party sensitive all right let's do some coding here
open not with tags I'm going to, first of all, define a constant named the or
and place the value of it as an h a multi because I'm going to be using the
threat of so [NOISE] and then I'm going to find some variables all these
variables or going to you have a string value which going to put council
names of my he is ~~~~~~~ so all of these three variables are different
variables because memorable needs and be a sense that and this is an example
so you get can clearly see that they're in fact different so [COUGH] this is
the output and as you can see all stories second intend their output in
different valleys because those are different variables which hold all these
different valley so that's how that works and now let me just give you an
example of a function inside the very inside the variable well you they can
do something like this sense quite is the square they of a number and use
the function of the value and then i would output for because that's
disk wired up for we can also use something called a tiny expression ~~~~~~~
and if you don't know how that works and here's a quick overview so first we
have a conditional expression here on the left side he'd followed by the
question mark if that condition in valleys to true then expression to is
going to be our value otherwise [UM] in theory is going to be the value which is
falls and those two are separate by the column so we can say something like
sorry and then let's say sign the result to the variable called ever going to
save equals and then we're going to around that through that seminary logic
expression ~~~~~~~ i should thing and then they coal and in case expression
is false and i told you know as and then output the evolve and how will be
equal to your over twenty-one use you're drinking because ages greater and
twenty-one so that's that way to assign the value using a term or the
expression now let me show you get something called variable variables so
the variable is something when we use a variable name in place after
variable has the name was hit a signed when we create the variable so for
example for example our variable named they valley of segued and so this
will be the same thing as a writing he calls whatever value is there because

 

when we right to dollar science the to value of the name is place inside of
this inside so this variable and so this would be the same pain is writing
set called sitting be console so now we have a new variable called sex
~~~~~~~ and we can go had an hour protect and ~~~~~~~ and used to be our tax
here and it's a six seen but console and now that we can see we have a sense
and variable so that's how that works also one if we have an area down named
planets with a bunch of different planets we can also use variable variable
so if we replace planets and specify the key like to hear this would be the
same thing as writing I'm actually signing valley too and mars was the roman
got to work so this will be the same as many mars equal from my got a tell
the war because we're specifying an area in place of the variable name and then
we they used the key and dick still which is equal to mars so that would be
mars dollars .
DevDigs (Dallas Website Development)

 
-