SlideShare ist ein Scribd-Unternehmen logo
1 von 9
Downloaden Sie, um offline zu lesen
Tutorial 5 – Learning CSS

CSS is a web-technology that has been around for quite some time, however, only in recent years has it
become a widely accepted practice for web design. CSS stands for Cascading Style Sheets and it allows
web designers to manage design elements site wide. In the previous activities, we were adding colors
and alignments to specific areas of web pages. Imagine if we ran a company whose main company color
was blue. What if the board of directors got together and changed that color to red? If a web designer
created these pages the normal way of changing each page, we would have to manually go through all
the pages and change the color from blue to red. Sounds pretty tedious…right? This is where CSS
comes in and makes web development really unique. Let’s start this exercise:




As you can see, this is a pretty basic HTML page. The only additional things we have done to this page
are adding a picture and putting the picture as well as some text inside of a div class. This can be done
by selecting the text and selecting “div class” on the insert menu.

Now let’s add some CSS attributes to this page!



Go to File and Select “New…”
Select a CSS document
Once you have selected it don’t make any changes yet (Dreamweaver make this part really easy). Just
simply save it, and know the location where you have saved it at.
Now go back to your main document that you have created.
From your “index.html” page,
Click the “Attach Style Sheet…” button




Now click on the “Browse…” button and select your file.
For this tutorial, we will add this CSS sheet as a link, but feel free to mess around with either setting.
Now click “OK”

As you can now see, the name of your file should be on the right hand side under the CSS panel.

          Now let’s add some properties for our CSS page. Click on the “New CSS rule” button
This window is the gateway to all your CSS development. It gives you the 3 types of definitions in CSS.
As the window describes, the 3 type types of CSS Rules can apply to:

Class – Using this type of CSS will change all tags that fall within a certain section of the HTML code.
Tag – This will change the appearance of any HTML element. For example the <p> element can be
changed to a predefined size or color.
Advanced – Different types of advanced CSS which can include the state of your links (normal, active or
clicked)

For the first example, let’s choose “tag” and from the drop down box, let’s choose the “p” element
You are now brought to another window that will let you alter the different attributes of the <p> tag.
Let’s make the Font Arial the color Red and the Text 18pt . Once you had made these changes, click
“OK” to accept.
Now look at our HTML page! All the different lines of text that had the <p> tag have now been changed
to our specifications. To change the attributes again, you will now see a “p” in the CSS panel
underneath the name of your CSS page. Double click that to make additional changes.




Now let’s go back and make another CSS rule, except this time, we’ll make it a class that we are going to
call “.text” (In these tutorials, we are adding a “.” to the beginning of each class make to make the
differentiation that they are a class in the HTML page) Now click “OK”
Let’s add the following properties:

Font – Courier New, Courier, monspace
Size – 24 pixels
Color – Green (#00FF00)

Click Ok once you have made the changes




WAIT A SEC! Why aren’t my changes made yet? The reason is that your HTML needs to specify what
area of the page we want affected by the new CSS class that we just defined.

If you click the div tag that is holding the text, you will see something really neat: Dreamweaver is giving
you the choices that you can apply. Choose the “text” class and your text will now be changed to meet
the criteria specified earlier.
You can now see that the page has been changed according to what we specified the “.text” class to be!
For the last part of this CSS tutorial, let’s take a look at the Florida TSA image located at the bottom
portion of the page. We know that there are three types of alignment – Left, Center and Right. For the
sake of this example, let’s say that we want to put our image in the area between left and center. It
doesn’t seem that something like this would be possible…but that is not the case with CSS. Let’s do the
following:

Create a new CSS rule
Call the rule: “.picclass”
Once the CSS Rule Definition page comes up, let’s add the following attributes:
On the left side, click on the Box tab and change the “Left Padding” to 100px
Our final page is now complete, based on what we went over in the tutorial, it should look something
like this:




Continue playing with CSS and make your pages look drastically different. The key point about
using CSS is that these attributes can apply to all the pages in a website. So rather than make
changes individually, you can link to a CSS page, and only have to make changes one time
rather than one time per page. Hopefully this tutorial will help you get your feet wet with CSS!

Weitere ähnliche Inhalte

Was ist angesagt?

INFO3775 Chapter 2 Part 2
INFO3775 Chapter 2 Part 2INFO3775 Chapter 2 Part 2
INFO3775 Chapter 2 Part 2
Jeff Byrnes
 
Master page and Theme ASP.NET with VB.NET
Master page and Theme ASP.NET with VB.NETMaster page and Theme ASP.NET with VB.NET
Master page and Theme ASP.NET with VB.NET
Shyam Sir
 
Visual process of using the text code
Visual process of using the text codeVisual process of using the text code
Visual process of using the text code
vren88
 

Was ist angesagt? (17)

How to-use-wordpress
How to-use-wordpressHow to-use-wordpress
How to-use-wordpress
 
INFO3775 Chapter 2 Part 2
INFO3775 Chapter 2 Part 2INFO3775 Chapter 2 Part 2
INFO3775 Chapter 2 Part 2
 
Css introduction
Css   introductionCss   introduction
Css introduction
 
CSS3 Introduction
CSS3 IntroductionCSS3 Introduction
CSS3 Introduction
 
Css inclusion
Css   inclusionCss   inclusion
Css inclusion
 
ASP.NET with VB.NET
 ASP.NET with VB.NET ASP.NET with VB.NET
ASP.NET with VB.NET
 
Html css
Html cssHtml css
Html css
 
INTRODUCTIONS OF CSS
INTRODUCTIONS OF CSSINTRODUCTIONS OF CSS
INTRODUCTIONS OF CSS
 
Master page and Theme ASP.NET with VB.NET
Master page and Theme ASP.NET with VB.NETMaster page and Theme ASP.NET with VB.NET
Master page and Theme ASP.NET with VB.NET
 
How to-inline-style-in-reactjs-
How to-inline-style-in-reactjs-How to-inline-style-in-reactjs-
How to-inline-style-in-reactjs-
 
Visual process of using the text code
Visual process of using the text codeVisual process of using the text code
Visual process of using the text code
 
How to edit your wik its
How to edit your wik itsHow to edit your wik its
How to edit your wik its
 
Sejda.com v pdf
Sejda.com v pdfSejda.com v pdf
Sejda.com v pdf
 
Style and Selector
Style and SelectorStyle and Selector
Style and Selector
 
Css intro
Css introCss intro
Css intro
 
Responsive Web Design (April 18th, Los Angeles)
Responsive Web Design (April 18th, Los Angeles)Responsive Web Design (April 18th, Los Angeles)
Responsive Web Design (April 18th, Los Angeles)
 
A complete html and css guidelines for beginners
A complete html and css guidelines for beginnersA complete html and css guidelines for beginners
A complete html and css guidelines for beginners
 

Andere mochten auch (20)

sample-06
sample-06sample-06
sample-06
 
Monteiro_WS
Monteiro_WSMonteiro_WS
Monteiro_WS
 
Ruby1_full
Ruby1_fullRuby1_full
Ruby1_full
 
php
phpphp
php
 
lab4_php
lab4_phplab4_php
lab4_php
 
REFERENCE - EPPCO - HR
REFERENCE - EPPCO - HRREFERENCE - EPPCO - HR
REFERENCE - EPPCO - HR
 
transcripts aman
transcripts amantranscripts aman
transcripts aman
 
HBCU TV Source Article
HBCU TV Source ArticleHBCU TV Source Article
HBCU TV Source Article
 
Circ31 1 Aprile 2008
Circ31 1 Aprile 2008Circ31 1 Aprile 2008
Circ31 1 Aprile 2008
 
Second Magazine Analysis
Second Magazine AnalysisSecond Magazine Analysis
Second Magazine Analysis
 
waagen-ecard
waagen-ecardwaagen-ecard
waagen-ecard
 
dr_3
dr_3dr_3
dr_3
 
Informing Faculty Case Template
Informing Faculty Case TemplateInforming Faculty Case Template
Informing Faculty Case Template
 
Ginipig Marathi Bestseller Novel Londhe And Dr. Shriniwas Kashalikar
Ginipig Marathi Bestseller Novel Londhe And Dr. Shriniwas KashalikarGinipig Marathi Bestseller Novel Londhe And Dr. Shriniwas Kashalikar
Ginipig Marathi Bestseller Novel Londhe And Dr. Shriniwas Kashalikar
 
Button
ButtonButton
Button
 
kalyan-resume
kalyan-resumekalyan-resume
kalyan-resume
 
tutorial7
tutorial7tutorial7
tutorial7
 
FreshAir2008
FreshAir2008FreshAir2008
FreshAir2008
 
Comunicato Stampa Ae 280607
Comunicato Stampa  Ae 280607Comunicato Stampa  Ae 280607
Comunicato Stampa Ae 280607
 
sts-scanner_tutorial
sts-scanner_tutorialsts-scanner_tutorial
sts-scanner_tutorial
 

Ähnlich wie Tutorial5

Girl Develop It Cincinnati: Intro to HTML/CSS Class 4
Girl Develop It Cincinnati: Intro to HTML/CSS Class 4Girl Develop It Cincinnati: Intro to HTML/CSS Class 4
Girl Develop It Cincinnati: Intro to HTML/CSS Class 4
Erin M. Kidwell
 

Ähnlich wie Tutorial5 (20)

Intro to CSS Presentation
Intro to CSS PresentationIntro to CSS Presentation
Intro to CSS Presentation
 
Introduction to css
Introduction to cssIntroduction to css
Introduction to css
 
Design and CSS
Design and CSSDesign and CSS
Design and CSS
 
Chapter 12
Chapter 12Chapter 12
Chapter 12
 
Css Founder.com | Cssfounder se
Css Founder.com | Cssfounder seCss Founder.com | Cssfounder se
Css Founder.com | Cssfounder se
 
The CSS Handbook
The CSS HandbookThe CSS Handbook
The CSS Handbook
 
CSS_tutorial_2
CSS_tutorial_2CSS_tutorial_2
CSS_tutorial_2
 
CSS_tutorial_2
CSS_tutorial_2CSS_tutorial_2
CSS_tutorial_2
 
Test revision
Test revisionTest revision
Test revision
 
Webexpration2007 ii
Webexpration2007 iiWebexpration2007 ii
Webexpration2007 ii
 
HTML to CSS Basics Exer 2.pptx
HTML to CSS Basics Exer 2.pptxHTML to CSS Basics Exer 2.pptx
HTML to CSS Basics Exer 2.pptx
 
Tfbyoweb.4.9.17
Tfbyoweb.4.9.17Tfbyoweb.4.9.17
Tfbyoweb.4.9.17
 
Tfbyoweb.4.9.17
Tfbyoweb.4.9.17Tfbyoweb.4.9.17
Tfbyoweb.4.9.17
 
Customizing Your WordPress Theme Using Firebug and Basic CSS
Customizing Your WordPress Theme Using Firebug and Basic CSSCustomizing Your WordPress Theme Using Firebug and Basic CSS
Customizing Your WordPress Theme Using Firebug and Basic CSS
 
Using class suffixes
Using class suffixesUsing class suffixes
Using class suffixes
 
Presentation 1 [autosaved]
Presentation 1 [autosaved]Presentation 1 [autosaved]
Presentation 1 [autosaved]
 
XPages OneUIv2 Theme Deep Dive
XPages OneUIv2 Theme Deep DiveXPages OneUIv2 Theme Deep Dive
XPages OneUIv2 Theme Deep Dive
 
Organize Your Website With Advanced CSS Tricks
Organize Your Website With Advanced CSS TricksOrganize Your Website With Advanced CSS Tricks
Organize Your Website With Advanced CSS Tricks
 
Girl Develop It Cincinnati: Intro to HTML/CSS Class 4
Girl Develop It Cincinnati: Intro to HTML/CSS Class 4Girl Develop It Cincinnati: Intro to HTML/CSS Class 4
Girl Develop It Cincinnati: Intro to HTML/CSS Class 4
 
E commerce-website
E commerce-websiteE commerce-website
E commerce-website
 

Mehr von tutorialsruby

&lt;img src="../i/r_14.png" />
&lt;img src="../i/r_14.png" />&lt;img src="../i/r_14.png" />
&lt;img src="../i/r_14.png" />
tutorialsruby
 
TopStyle Help &amp; &lt;b>Tutorial&lt;/b>
TopStyle Help &amp; &lt;b>Tutorial&lt;/b>TopStyle Help &amp; &lt;b>Tutorial&lt;/b>
TopStyle Help &amp; &lt;b>Tutorial&lt;/b>
tutorialsruby
 
The Art Institute of Atlanta IMD 210 Fundamentals of Scripting &lt;b>...&lt;/b>
The Art Institute of Atlanta IMD 210 Fundamentals of Scripting &lt;b>...&lt;/b>The Art Institute of Atlanta IMD 210 Fundamentals of Scripting &lt;b>...&lt;/b>
The Art Institute of Atlanta IMD 210 Fundamentals of Scripting &lt;b>...&lt;/b>
tutorialsruby
 
&lt;img src="../i/r_14.png" />
&lt;img src="../i/r_14.png" />&lt;img src="../i/r_14.png" />
&lt;img src="../i/r_14.png" />
tutorialsruby
 
&lt;img src="../i/r_14.png" />
&lt;img src="../i/r_14.png" />&lt;img src="../i/r_14.png" />
&lt;img src="../i/r_14.png" />
tutorialsruby
 
Standardization and Knowledge Transfer – INS0
Standardization and Knowledge Transfer – INS0Standardization and Knowledge Transfer – INS0
Standardization and Knowledge Transfer – INS0
tutorialsruby
 
0047ecaa6ea3e9ac0a13a2fe96f4de3bfd515c88f5d90c1fae79b956363d7f02c7fa060269
0047ecaa6ea3e9ac0a13a2fe96f4de3bfd515c88f5d90c1fae79b956363d7f02c7fa0602690047ecaa6ea3e9ac0a13a2fe96f4de3bfd515c88f5d90c1fae79b956363d7f02c7fa060269
0047ecaa6ea3e9ac0a13a2fe96f4de3bfd515c88f5d90c1fae79b956363d7f02c7fa060269
tutorialsruby
 
0047ecaa6ea3e9ac0a13a2fe96f4de3bfd515c88f5d90c1fae79b956363d7f02c7fa060269
0047ecaa6ea3e9ac0a13a2fe96f4de3bfd515c88f5d90c1fae79b956363d7f02c7fa0602690047ecaa6ea3e9ac0a13a2fe96f4de3bfd515c88f5d90c1fae79b956363d7f02c7fa060269
0047ecaa6ea3e9ac0a13a2fe96f4de3bfd515c88f5d90c1fae79b956363d7f02c7fa060269
tutorialsruby
 
BloggingWithStyle_2008
BloggingWithStyle_2008BloggingWithStyle_2008
BloggingWithStyle_2008
tutorialsruby
 
BloggingWithStyle_2008
BloggingWithStyle_2008BloggingWithStyle_2008
BloggingWithStyle_2008
tutorialsruby
 
cascadingstylesheets
cascadingstylesheetscascadingstylesheets
cascadingstylesheets
tutorialsruby
 
cascadingstylesheets
cascadingstylesheetscascadingstylesheets
cascadingstylesheets
tutorialsruby
 

Mehr von tutorialsruby (20)

&lt;img src="../i/r_14.png" />
&lt;img src="../i/r_14.png" />&lt;img src="../i/r_14.png" />
&lt;img src="../i/r_14.png" />
 
TopStyle Help &amp; &lt;b>Tutorial&lt;/b>
TopStyle Help &amp; &lt;b>Tutorial&lt;/b>TopStyle Help &amp; &lt;b>Tutorial&lt;/b>
TopStyle Help &amp; &lt;b>Tutorial&lt;/b>
 
The Art Institute of Atlanta IMD 210 Fundamentals of Scripting &lt;b>...&lt;/b>
The Art Institute of Atlanta IMD 210 Fundamentals of Scripting &lt;b>...&lt;/b>The Art Institute of Atlanta IMD 210 Fundamentals of Scripting &lt;b>...&lt;/b>
The Art Institute of Atlanta IMD 210 Fundamentals of Scripting &lt;b>...&lt;/b>
 
&lt;img src="../i/r_14.png" />
&lt;img src="../i/r_14.png" />&lt;img src="../i/r_14.png" />
&lt;img src="../i/r_14.png" />
 
&lt;img src="../i/r_14.png" />
&lt;img src="../i/r_14.png" />&lt;img src="../i/r_14.png" />
&lt;img src="../i/r_14.png" />
 
Standardization and Knowledge Transfer – INS0
Standardization and Knowledge Transfer – INS0Standardization and Knowledge Transfer – INS0
Standardization and Knowledge Transfer – INS0
 
xhtml_basics
xhtml_basicsxhtml_basics
xhtml_basics
 
xhtml_basics
xhtml_basicsxhtml_basics
xhtml_basics
 
xhtml-documentation
xhtml-documentationxhtml-documentation
xhtml-documentation
 
xhtml-documentation
xhtml-documentationxhtml-documentation
xhtml-documentation
 
CSS
CSSCSS
CSS
 
CSS
CSSCSS
CSS
 
0047ecaa6ea3e9ac0a13a2fe96f4de3bfd515c88f5d90c1fae79b956363d7f02c7fa060269
0047ecaa6ea3e9ac0a13a2fe96f4de3bfd515c88f5d90c1fae79b956363d7f02c7fa0602690047ecaa6ea3e9ac0a13a2fe96f4de3bfd515c88f5d90c1fae79b956363d7f02c7fa060269
0047ecaa6ea3e9ac0a13a2fe96f4de3bfd515c88f5d90c1fae79b956363d7f02c7fa060269
 
0047ecaa6ea3e9ac0a13a2fe96f4de3bfd515c88f5d90c1fae79b956363d7f02c7fa060269
0047ecaa6ea3e9ac0a13a2fe96f4de3bfd515c88f5d90c1fae79b956363d7f02c7fa0602690047ecaa6ea3e9ac0a13a2fe96f4de3bfd515c88f5d90c1fae79b956363d7f02c7fa060269
0047ecaa6ea3e9ac0a13a2fe96f4de3bfd515c88f5d90c1fae79b956363d7f02c7fa060269
 
HowTo_CSS
HowTo_CSSHowTo_CSS
HowTo_CSS
 
HowTo_CSS
HowTo_CSSHowTo_CSS
HowTo_CSS
 
BloggingWithStyle_2008
BloggingWithStyle_2008BloggingWithStyle_2008
BloggingWithStyle_2008
 
BloggingWithStyle_2008
BloggingWithStyle_2008BloggingWithStyle_2008
BloggingWithStyle_2008
 
cascadingstylesheets
cascadingstylesheetscascadingstylesheets
cascadingstylesheets
 
cascadingstylesheets
cascadingstylesheetscascadingstylesheets
cascadingstylesheets
 

Kürzlich hochgeladen

Histor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slideHistor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slide
vu2urc
 
Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and Myths
Joaquim Jorge
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI Solutions
Enterprise Knowledge
 

Kürzlich hochgeladen (20)

Histor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slideHistor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slide
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
 
Exploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone ProcessorsExploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone Processors
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024
 
Handwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsHandwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed texts
 
08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men
 
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
Evaluating the top large language models.pdf
Evaluating the top large language models.pdfEvaluating the top large language models.pdf
Evaluating the top large language models.pdf
 
Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and Myths
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)
 
How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonets
 
GenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdfGenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdf
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI Solutions
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day Presentation
 
Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
Boost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityBoost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivity
 
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
 

Tutorial5

  • 1. Tutorial 5 – Learning CSS CSS is a web-technology that has been around for quite some time, however, only in recent years has it become a widely accepted practice for web design. CSS stands for Cascading Style Sheets and it allows web designers to manage design elements site wide. In the previous activities, we were adding colors and alignments to specific areas of web pages. Imagine if we ran a company whose main company color was blue. What if the board of directors got together and changed that color to red? If a web designer created these pages the normal way of changing each page, we would have to manually go through all the pages and change the color from blue to red. Sounds pretty tedious…right? This is where CSS comes in and makes web development really unique. Let’s start this exercise: As you can see, this is a pretty basic HTML page. The only additional things we have done to this page are adding a picture and putting the picture as well as some text inside of a div class. This can be done by selecting the text and selecting “div class” on the insert menu. Now let’s add some CSS attributes to this page! Go to File and Select “New…” Select a CSS document Once you have selected it don’t make any changes yet (Dreamweaver make this part really easy). Just simply save it, and know the location where you have saved it at. Now go back to your main document that you have created.
  • 2. From your “index.html” page, Click the “Attach Style Sheet…” button Now click on the “Browse…” button and select your file. For this tutorial, we will add this CSS sheet as a link, but feel free to mess around with either setting. Now click “OK” As you can now see, the name of your file should be on the right hand side under the CSS panel. Now let’s add some properties for our CSS page. Click on the “New CSS rule” button
  • 3. This window is the gateway to all your CSS development. It gives you the 3 types of definitions in CSS. As the window describes, the 3 type types of CSS Rules can apply to: Class – Using this type of CSS will change all tags that fall within a certain section of the HTML code. Tag – This will change the appearance of any HTML element. For example the <p> element can be changed to a predefined size or color. Advanced – Different types of advanced CSS which can include the state of your links (normal, active or clicked) For the first example, let’s choose “tag” and from the drop down box, let’s choose the “p” element
  • 4. You are now brought to another window that will let you alter the different attributes of the <p> tag. Let’s make the Font Arial the color Red and the Text 18pt . Once you had made these changes, click “OK” to accept.
  • 5. Now look at our HTML page! All the different lines of text that had the <p> tag have now been changed to our specifications. To change the attributes again, you will now see a “p” in the CSS panel underneath the name of your CSS page. Double click that to make additional changes. Now let’s go back and make another CSS rule, except this time, we’ll make it a class that we are going to call “.text” (In these tutorials, we are adding a “.” to the beginning of each class make to make the differentiation that they are a class in the HTML page) Now click “OK”
  • 6. Let’s add the following properties: Font – Courier New, Courier, monspace Size – 24 pixels Color – Green (#00FF00) Click Ok once you have made the changes WAIT A SEC! Why aren’t my changes made yet? The reason is that your HTML needs to specify what area of the page we want affected by the new CSS class that we just defined. If you click the div tag that is holding the text, you will see something really neat: Dreamweaver is giving you the choices that you can apply. Choose the “text” class and your text will now be changed to meet the criteria specified earlier.
  • 7. You can now see that the page has been changed according to what we specified the “.text” class to be!
  • 8. For the last part of this CSS tutorial, let’s take a look at the Florida TSA image located at the bottom portion of the page. We know that there are three types of alignment – Left, Center and Right. For the sake of this example, let’s say that we want to put our image in the area between left and center. It doesn’t seem that something like this would be possible…but that is not the case with CSS. Let’s do the following: Create a new CSS rule Call the rule: “.picclass” Once the CSS Rule Definition page comes up, let’s add the following attributes: On the left side, click on the Box tab and change the “Left Padding” to 100px
  • 9. Our final page is now complete, based on what we went over in the tutorial, it should look something like this: Continue playing with CSS and make your pages look drastically different. The key point about using CSS is that these attributes can apply to all the pages in a website. So rather than make changes individually, you can link to a CSS page, and only have to make changes one time rather than one time per page. Hopefully this tutorial will help you get your feet wet with CSS!