LaptopGuard AcademyLaptopGuard Academy
  • Kursus Online
    • MODUL

      • LGA Schematic 101
      • Transistor 101
      • Power Regulator & IC’s
      • Kapasitor
      • Resistor
      • Reballing Class
      • Dioda

      Promo

      • BASIC Class
      • ADVANCE Class
      • MASTER Class
  • Blog
  • Program Afiliasi
      • DAFTAR LOGIN

        Connect with:

        Login with Facebook Login with Google

        Login with your site account

        Lost your password?

        Not a member yet? Register now

    • Kursus Online
      • MODUL

        • LGA Schematic 101
        • Transistor 101
        • Power Regulator & IC’s
        • Kapasitor
        • Resistor
        • Reballing Class
        • Dioda

        Promo

        • BASIC Class
        • ADVANCE Class
        • MASTER Class
    • Blog
    • Program Afiliasi
    • Home
    • Colors

    Colors

    • Posted by anton
    • Date June 5, 2015
    CSS brings 16,777,216 colors to your disposal. They can take the form of a name, an RGB (red/green/blue) value or ahex code.
    The following values, to specify full-on as red-as-red-can-be, all produce the same result:

    • red
    • rgb(255,0,0)
    • rgb(100%,0%,0%)
    • #ff0000
    • #f00

    Predefined color names include aqua, black, blue, fuchsia, gray, green, lime, maroon, navy, olive, orange, purple,red, silver, teal, white, and yellow. transparent is also a valid value.

    With the possible exception of black and white, color names have limited use in a modern, well-designed web sites because they are so specific and limiting.

    The three values in the RGB value are from 0 to 255, 0 being the lowest level (no red, for example), 255 being the highest level (full red, for example). These values can also be a percentage.

    Hexadecimal (previously and more accurately known as “sexadecimal”) is a base-16 number system. We are generally used to the decimal number system (base-10, from 0 to 9), but hexadecimal has 16 digits, from 0 to f.

    The hex number is prefixed with a hash character (#) and can be three or six digits in length. Basically, the three-digit version is a compressed version of the six-digit (#ff0000 becomes #f00, #cc9966 becomes #c96, etc.). The three-digit version is easier to decipher (the first digit, like the first value in RGB, is red, the second green and the third blue) but the six-digit version gives you more control over the exact color.

    color and background-color

    Colors can be applied by using color and background-color (note that this must be the American English “color” and not “colour”).

    A blue background and yellow text could look like this:

    
    h1 {
        color: yellow;
        background-color: blue;
    }
    

    These colors might be a little too harsh, so you could change the code of your CSS file for slightly different shades:

    
    body {
        font-size: 14px;
        color: navy;
    }
    
    h1 {
        color: #ffc;
        background-color: #009;
    }
    

    Save the CSS file and refresh your browser. You will see the colors of the first heading (the h1 element) have changed to yellow and blue.

    You can apply the color and background-color properties to most HTML elements, including body, which will change the colors of the page and everything in it.

    • Share:
    anton

    Previous post

    Applying CSS
    June 5, 2015

    Next post

    Text
    5 June, 2015

    Search

    Categories

    • Blog
    • Business
    • Design / Branding
    • Uncategorized

    Latest Courses

    Learn Python – Interactive Python Tutorial

    Learn Python – Interactive Python Tutorial

    Rp 69
    Your Complete Guide to Photography

    Your Complete Guide to Photography

    Rp 60
    Learning jQuery Mobile for Beginners

    Learning jQuery Mobile for Beginners

    Rp 30

    Latest Posts

    demo_image
    Why You Should Read Every Day
    20Jan2016
    demo_image
    Relaxing after work
    20Jan2016
    demo_image
    Online Learning Glossary
    20Jan2016
    • About Us
    • Blog
    • Contact
    • Become a Teacher

    LAPTOP GUARD ACADEMY

    Laptop Guard Academy adalah pusat pelatihan laptop yang menghasilkan alumni handal dan memiliki kompetensi yang berkualitas. Dan sekarang kami memiliki kelas online yang dapat diakses dimana saja, kapan saja.

    LaptopGuard Academy

    Jika ada yang ingin berkonsultasi lebih lanjut, silakan kontak langsung melalui akun Facebook saya Maula Hassan
    PS:
    Info tentang pelatihan teknisi laptop silakan hubungi
    081929041569
    085228201684
    BB 3144411b
    Laptopguard.co.id

    Jl. Glagahsari No. 100
    Umbulharjo, D.I. Yogyakarta
    Indonesia, 55164

    +62 274 419927

    academy@laptopguard.co.id

    JADI TEKNISI HANDAL SEKARANG JUGA!
    Daftar GRATIS Sekarang
    • Privacy
    • Terms
    • Sitemap

    Copyright © 2016 LaptopGuard Academy. All rights reserved.

    Made with ♥ in Yogyakarta by Pixld.co.