Casecade Style Sheet
ada 3 metode penerapan pemrograman CSS:
1. Inline style sheet,
metode ini memaki atribut style pada semua tag html, contoh <h1 style="color:red;">
2. Embeded Style sheet
metode ini menerapakan pemrograman CSS yang diapit oleh tag <style> di file html.
contoh:
<style type="text/css">
h1{
color:red;
}
</style>
3. Link style sheet
metode ini penyimpan pemrograman CSS khusus pada file css, dan dikombinasikan dengan file html dengan menggunakn tag link, contoh:
<link rel="stylesheet" type="text/css" href="filecss.css">
secara umum struktur pemrograman CSS adalah
contoh,
h1{
color:red;
}
h1: sebagai selector
{....}:deklarasi
color: properties
red; value, nilai dari properties
0 comments:
Post a Comment