FOR THOSE WHO HAVENT READ PART 1 ARE ADVISED TO CLICK HERE
PARAGRAPH
on this section , we will talk more about paragraph , creating lines , and breaks
SIMPLE PARAGRAPH
<p>word</p>simple code to write a paragraph , basically when you want to type a paragraph all you need is to make <p> , type type type and close with </p> , thats all :D
BREAKS
<br /> remember there is a spacing between br and /break the sentence , act as enter in this case . example :
<p>this is my first sentence<br />this is my second sentence</p>will result in :
this is my first sentence
this is my second sentence
LINES
<hr /> remember there is a spacing between hr and /hr is a line , yep a simple line . example :
<p>this is my first sentence<hr />this is my second sentence</p>will result in
this is my first sentence
this is my second sentence
HEADINGS
headings , ranged from 1(biggest) to 6(smallest) in terms of size . it works the same as paragraph(<p>word</p>) , lets try couple examples for easy understanding .this is font size used in paragraph for comparison
| CODE EXAMPLE | RESULTS |
|---|---|
| <h1>word</h1> | word |
| <h2>word</h2> | smaller word |
| <h4>word</h4> | even smaller word |
| <h6>word</h6> | smallest word |
TEXT FORMATTING
you might get used to press B for bold and I for italic (or other text formatting) but dont know what code that modifies it , this part will explain all you need to know .| CODE | RESULTS |
|---|---|
| <b>WORD</b> | BOLDED WORD |
| <i>WORD</i> | ITALIC WORD |
| <s>WORD</s> OR <strike>WORD</strike> | |
| <u>WORD</u> | UNDERLINED WORD |
| <sub>WORD</sub> | SUBSCRIPTED WORD |
| <sup>WORD</sup> | SUPERSCRIPTED WORD |
there are lots of things you can explore on W3SCHOOLS formatting part but so far this is all needed to tackle P10 problem
STYLE
style are modifier for....most things that you could have imagine , it changes font size , font type , font color , etc .
usually style are located after an element , examples : <b style="~~~">text</b>
can also put styles on paragraphs , headings , etc
| TO MODIFY | CODE | RESULTS |
|---|---|---|
| FONT COLOR | <p style="color:red">text</p> | this is a paragraph with red font color |
| BACKGROUND COLOR | <p style="background-color:yellow">text</p> | this is paragraph with yellow background color |
| TEXT SIZE | <p style="font-size:25px">word</p> | this word size is 25px |
or maybe both , using combine method , example : <p style="background-color:yellow ; color:red">word</p>
this is paragraph with yellow background color and red text
if you want to check list of colors you can use , try this link to W3SCHOOLS , you dont need to remember the codes , just the exact name of the color and there you go..try experiment with some colors =D
COMMENTS
<! comment>comments are instructions or descriptions inside the code that will not be shown/displayed when you open your HTML webpage , its main purpose is to improve code readability and understanding for those other than the author(creator)
sometimes people create messy codes , but with comments other people who read it can know whats the purpose of this part of code , etc
type this sentence below in your notepad++ and see if it is actually displayed or not in the browser(remember to replace < > with < >)
<! THIS IS A COMMENT>
No comments:
Post a Comment