tanszek:oktatas:techcomm:cascading_style_sheets
Differences
This shows you the differences between two versions of the page.
| Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
| tanszek:oktatas:techcomm:cascading_style_sheets [2024/10/01 09:30] – [8. Background styling] kissa | tanszek:oktatas:techcomm:cascading_style_sheets [2024/10/01 10:32] (current) – [3. Defining CSS styles] kissa | ||
|---|---|---|---|
| Line 90: | Line 90: | ||
| <code CSS> | <code CSS> | ||
| + | /* styles.css */ | ||
| p { | p { | ||
| color: blue; | color: blue; | ||
| Line 239: | Line 240: | ||
| ==== 9. Margin, padding and border ==== | ==== 9. Margin, padding and border ==== | ||
| - | The '' | + | The **box model** |
| {{: | {{: | ||
| - | < | + | The '' |
| - | div { | + | |
| - | margin: 10px; | + | The example below shows how to format a button. Try what happens when you change the button' |
| - | padding: 20px; | + | |
| - | border: 1px solid black; | + | < |
| - | border-radius: | + | < |
| - | } | + | < |
| + | < | ||
| + | | ||
| + | < | ||
| + | .styled-button { | ||
| + | color: green; | ||
| + | background-color: | ||
| + | | ||
| + | padding: 20px; | ||
| + | border: 1px solid red; | ||
| + | border-radius: | ||
| + | } | ||
| + | </ | ||
| + | </ | ||
| + | < | ||
| + | < | ||
| + | <button class=" | ||
| + | < | ||
| + | </ | ||
| + | </ | ||
| </ | </ | ||
| Line 273: | Line 293: | ||
| font-weight: | font-weight: | ||
| font-style: italic; | font-style: italic; | ||
| - | |||
| text-decoration: | text-decoration: | ||
| text-align: justify; | text-align: justify; | ||
| } | } | ||
| </ | </ | ||
| + | |||
| + | If you are interested, [[https:// | ||
| ==== 12. Exercise ==== | ==== 12. Exercise ==== | ||
| - | Create the following webpage | + | Create the following webpage using HTML and CSS. Use embedded |
| - | Feel free to use online resources (e.g. [[https:// | + | Feel free to use online resources (e.g. [[https:// |
| {{: | {{: | ||
tanszek/oktatas/techcomm/cascading_style_sheets.1727775038.txt.gz · Last modified: 2024/10/01 09:30 by kissa
