0% found this document useful (0 votes)
24 views

HTML Note

Programming languages allow programmers to write instructions that computers can understand. HTML is the most widely used programming language for creating web pages and was created by Tim Berners-Lee in 1991. CSS is used to control the presentation and layout of web pages and allows formatting of text, colors, spacing, and backgrounds. PHP is a server-side scripting language that allows developers to create dynamic content that interacts with databases.

Uploaded by

tvibes078
Copyright
© © All Rights Reserved
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
24 views

HTML Note

Programming languages allow programmers to write instructions that computers can understand. HTML is the most widely used programming language for creating web pages and was created by Tim Berners-Lee in 1991. CSS is used to control the presentation and layout of web pages and allows formatting of text, colors, spacing, and backgrounds. PHP is a server-side scripting language that allows developers to create dynamic content that interacts with databases.

Uploaded by

tvibes078
Copyright
© © All Rights Reserved
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 5

PROGRAMMING LANGUAGE

A programming language is a coded language use by programmers to write instructions that


computer can understand to do what the programmer or computer user want. Computer or
machine speaks 1/0 language. They don’t understand human language. Prominent among
programming languages include python.
LEVELS OF PROGRAMMING LANGUAGE
 Low
 el programming language: it is close to computer language
 High-level programming language: it is close to human language

HYPERTEXT MARKUP LANGUAGE [HTML]


HTML is the most widely use programming language for writing web pages. It was created by
Berners-Lee in 1991. Currently the most commonly used are HTML4, publish in 1991 and
HTML5, publish in 2012

Precondition for HTML


 Web server e.g. XAMPP
 Text editor e.g. visual studio code

HTML ELEMENT
An element is a fundamental component of the structure of an html document that begins
with a start tag. If may also have content and end tag. Some example of element are head,
body, tables, paragraph, break, image and list. Html element are define by tags for browser
and element can have plain text content and other forms of content or both as analyses in
the following table
Opening tag content Closing tag
<p> This is a paragraph </p>
<h> This is heading </h>
<div> This is a divisions </div>
<b r />
<img src=”image url”>

HTML ATTRIBUTE
An attribute is use to define the characteristic of an html element. Attribute is additional
information that is included inside a start tag

HTML list tag


Html list tag are use to present list of information in well formed and semantic way . all list
must contain one or more list element are the type of lisdt in html include the following ;
 Un-ordered list: it is used to create a list of related items , in no particular order. Un-
ordered list is created using the <ul> element and each list items start with <li>
element
 Ordered list: it is used to create a list of related item , in a specific order . order list
are used when the order of list item is important .the list item are marked with
number . order list is created using the <ol>

Link tag
Link or hyperlink is a connection from one web resource to another.links allow users to
move seamlessly from one stage to another. A link is specified using the anchor tag <a> and
an anything between the opening <a> tag and the closing </a>tag become part of the link a
user can click

HTML TABLE TAGS


The html tables allow web authors to arrange data like, text, images, links,product listing,
customer details,financial report,other tables,etc. into rows and column of cells. the html
table are created using the <table >tag in which <tr> tag is used to create table rows and
<td>tag is used to create data cell. One can also define a cell as a header for a group of table
cells using <th>element

CELL PADING
Tables cells are sizes large enough to fit the content by default. To add more space around
the content is the tqbles cells,padding property can be use ,padding provide space inside
container.padding goes around all four size of the content
CELL SPACING
Cells spacing are use to adjust the whitespace in the tables cells. It is used to defined the
width of the border
HTML FORMS
Html forms are required when you want to collect some information the site visitors. User
input such as contact details ;like names ,email address,phone numbers or details like credit
card information etc are always collected with forms
FORMS CPONTRIOLS
Forms contain special element called control like text field or input box,check buttons,radio
buttons,submit buttons .etc users generally complete a forms buy modifying is controls eg
entry text,selecting items etc. and submitting the forms to webserver for further processing.
Font tag is use to create an html forms
TWO FORMS METHOD WITH WHICH BROWSER CLIENT SEND
MESSAGE
 Post method : after url their will not be something else on the url bar of the browser.
Hence, using post is more secure bcoz some fact can not be seen by viewers
 Get method : after url their will be a question mark succeded by a bunch of
information on the url bar of the browser

CASCADING STYLE SHEET (CSS)


CSS is design language for simplifying the process of making web page presentable . using
css, you can control the color of a text , the style of the font. The spacing between
paragraph , how column are size and layout what background images or colors are used, as
well as varieties of other effect are use .css is created and maintained through the
specification of css working group , A group og people within the world wide web
consortium (W3C) .
SYNTAX OF CSS
A style is made up of three part . They are the following
 SELECTOR: A selector is an html tag at which a style will be applied
 DECLARATION: It determines how the element are formatted on a web page . it
consist of the following :
 PROPERTY: A property is a type of attribute of html tag
 VALUE : A value is features assign to property
Example: h1{color:blue;text-align:center;}
Selector declaration property value
H1 Color: blue color blue
hi Text-align:centre Text-align center

TYPE OF CSS
The most common type of css are the following
 Embedded css: this is the css whose rule is placed in-between a pair of style tags
within the head tag '
 In-line CSS or css of style attribute: This is use to define a unique style rule for a
single html element in the opening tag
 External css : this is a separte text file with .css extension. Styles rule are define
within the .css file but are included in an html document using <link> element within
the head tag of the html file in order to link the rules in the css file to it

TYPE OF CSS SELECTOR


Type of css selector are use to choose the content that you want to style. The most
commonly use css selector are the following:
 Universal selector : it select all the element on the web page.universal selector is
always denoted by an hysteric(*)
 Element selector or type selector: it matches the html element having the same
name as the selector name
 id selector : it searches for the element that has thessme id name as the one
specified in the css row and matches it with i.d attribute value.i.d selector is used
with the help of (#)sihn before the id name is declared
 CLASS SELECTOR : class selector is declared by using a (.)dot following by the name
of the class
WEB HOSTING

A web host is a company that has many computers permanently connected to he internet.
When a web page is placd on their computers, everyone in the world will be able to connect
to it and view it. The famous among the web hosts include the following:
 Bluehost
 GoDaddy
 HostGator
 Wordpress.com
 Google cloud
 Amazon web services
There is a need to sign up for an account with a webhost for a website to have a home. After
you have designed your webpages, you will need to transfer them to your web host
computer called a web server

GETTING DOMAIN NAME


The first thing you need to do before anything else is to get yourself a domain name. This is
the name you want to give to your website such as Onsite.com. To get a domain name, you
have to pay an annual fee to a registrar for the right to use that name. Getting a name does
not get a website or anything like that. You still need to upload your site folder and files to
your host server. Getting a domain name is analogous to getting a business name. Getting a
web hosting account is comparable to renting office or shop premises for your business.
There is still a need to load market into the shop.

HYPER TEXT PRE-PROCESSOR(PHP)


PHP initially known as personal homepage is a programming language that allows web
developer to create dynamic content that interacts with data basis. The first version of PHP
was introduced in 1994 by Rasmus Ladolf. PHP is known as a server sided language and it
probably the most common scripting language on the web-page. The most popular of what
php stands for is hypertext pre-processor but that would make it HPP. An alternative
explanation for the abbreviation of PHP is that the initials come from the earliest version of
the program which was called personal homepage tools for which the letters php are in the
right order.
COMMON USE OF PHP
PHP can be used for the following:
 PHP can handle forms
 PHP can add, delete and modify elements within your database
 PHP can restrict user to access some pages of your website
 PHP can encrypt data
 PHP is used for accessing cookies variables and setting cookies
PRECONDITIONS OF PHP
 PHP file
 Web-server: Web server include Microsoft internet information service(IIS) and Apache
but the one supported by PHP is Apache
 Data-base Server: Database server mode include ASP, JSP, and MySQL but the one
supported by php is MySQl
For convenience sake download one of the following bitnami stacks, install it and start the
required servers each time they are needed:
 LAMP
 WAMP
 XAMP
 MAMP
VERIFICATION THAT PHP IS WORKING
To verify that php is working fine do the following
 Open a text editor(notepad) and type <?php phpinfo(?)

?>
 Save the file with info.php to C:\xampp\htdocs
 Tyoe localhost\info.PHP
COMMENT
A comment is a portion of code that will not be executed my machine because it is only
meant for human reader. comment may be made to remind of what code does. It can also
be a block of code under experiment I.e code under experiment can be commented out
instead of being deleted
PHP VARIABLE
A variable is a storage location paired with an associated symbolic name which contains
some known or unknown value. A variable is used to store data to the reused data. To
conveniently and repeatedly refers to stored value in php, variable is defined by the
combination of $,identifier(name) and value. The equal sign is used to assign value to
variable in php. Variable name is always to the left of equal to and variable value to the right
of equal to sign. php does not require declaration of php type. It automatically assign equal
to a value but whenever a variablle name is used, it will be preceeded by dollar sign.
DECLARATION, INNIATIALIZATION, DEFINITION AND INSTANCATION
DECLARTION: This is to introduce the new name or more into a program.
INNITIALIZATION: This is to assign a value to a variable
DEFFINITION: This is to declare an initialised variable
INSTANCATION: this means to create specific class. It also means to create new instances of
objects to be used in a program

PHP DATA TYPES


Data types supported by php include the following
 Intergers: These are whole numbers
 Floats: Floating number are also known as double. They are
 Boolean: it has 2 possible value True or False. If the value is rue it will show 1
 Strings are sequence of characters which can be letters numbers or combination
enclosed in single or double quote; String concatenation: this is to join two or more
strings together

PHP SELECTION STATEMENTS


PHP supports two selection: if and switch. These statements allow to control the flow of a
program execution based upon conditions known only during run time
IF STATEMENT
If statement is used to execute a block of code only if the specified condition is true. If the
condition is false then the statement will be bypassed.
If-else statement:
Else condition is usually used when you have judge an alternative statement on the basis on
the preceding statement, in if and else statement if the condition is true the first statement
will be executed buut if the condition is false the second statement will be executed
FUNCTION
Function is a group of usable code which can be called anywhere in a program to perform
some related actions. Function eliminate the need of writing code repeatedly
BUILT IN FUNCTION VS USER DEFINED FUNCTION

You might also like