├── .DS_Store ├── CSS └── style.css ├── LICENSE ├── Learn to Code - Intro to HTML & CSS.pdf ├── README.md └── index.html /.DS_Store: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/GalvanizeOpenSource/Learn-To-Code-HTML-CSS/e28a917417662910986464c109df59c693fcde63/.DS_Store -------------------------------------------------------------------------------- /CSS/style.css: -------------------------------------------------------------------------------- 1 | * {margin: 0; padding: 0; outline: 0;} 2 | 3 | 4 | body { 5 | color: #e5e5e5; 6 | font-size: 12px; 7 | background:#bfbfbf; 8 | } 9 | 10 | 11 | h1, h2 { 12 | font-weight: 300; 13 | margin:0 0 15px 0; 14 | } 15 | 16 | 17 | h1 { 18 | font-size: 36px; 19 | letter-spacing: -1px; 20 | line-height: 100%; 21 | } 22 | 23 | 24 | h2 { 25 | font-size: 24px; 26 | } 27 | 28 | 29 | p { 30 | margin: 0 0 15px 0; 31 | } 32 | 33 | a { 34 | color: #3e3e3e; 35 | } 36 | 37 | 38 | .clear { 39 | clear: both; 40 | } 41 | .wrap { 42 | width: 100%; 43 | max-width: 1600px; 44 | min-width: 960px; 45 | z-index: 10; 46 | position: relative; 47 | margin: 0 auto; 48 | padding: 0; 49 | } 50 | 51 | .section { 52 | width: 100%; 53 | max-width: 1600px; 54 | min-width: 960px; 55 | z-index: 10; 56 | position: relative; 57 | margin: 0 auto; 58 | padding: 0 0 20px 0; 59 | height: 500px; 60 | } 61 | 62 | .section img { 63 | width: auto; 64 | height: 50%; 65 | } 66 | 67 | .inner { 68 | width: 960px; 69 | margin: 0 auto; 70 | position: relative; 71 | min-height: 50px; 72 | padding:30px 0; 73 | font-size: 18px; 74 | font-family: 'Open Sans', sans-serif; 75 | font-weight: 300; 76 | } 77 | 78 | .inner:after { 79 | content: ""; 80 | display: table; 81 | clear: both; 82 | } 83 | 84 | 85 | .subMenu { 86 | height: 50px; 87 | z-index: 1000; 88 | width: 100%; 89 | background: #0977bc; 90 | } 91 | 92 | .subMenu .inner { 93 | padding:0; 94 | font-weight: 400; 95 | margin: 0 auto; 96 | } 97 | 98 | 99 | .subNavBtn { 100 | display: block; 101 | height: 35px; 102 | width: 10%; 103 | float: left; 104 | margin: 0px 0px 0 0; 105 | text-decoration: none; 106 | font-size: 14px; 107 | padding: 15px 2% 0 2%; 108 | text-align: center; 109 | 110 | color: #fff; 111 | } 112 | .subMenu a:hover { 113 | background: #1783c7; 114 | } 115 | 116 | .active { 117 | background: #25aae1; 118 | } 119 | .end { 120 | margin: 0; 121 | } 122 | 123 | /*.photoWrapper { 124 | 125 | }*/ 126 | 127 | 128 | /* SECTIONS */ 129 | .sTop { 130 | min-height: 130px; 131 | background:#fff; 132 | color:#3d3d3d; 133 | padding: 50px 0; 134 | height: 300px; 135 | } 136 | 137 | .s1 { 138 | background:#184764; 139 | color:#fff; 140 | } 141 | 142 | 143 | .s2 { 144 | background: #313131; 145 | } 146 | .s2 a { 147 | color: #fff; 148 | } 149 | 150 | .s3 { 151 | background: #1b83b3; 152 | } 153 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | The MIT License (MIT) 2 | 3 | Copyright (c) 2015 GalvanizeOpenSource 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | 23 | -------------------------------------------------------------------------------- /Learn to Code - Intro to HTML & CSS.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/GalvanizeOpenSource/Learn-To-Code-HTML-CSS/e28a917417662910986464c109df59c693fcde63/Learn to Code - Intro to HTML & CSS.pdf -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # Learn to Code HTML & CSS 2 | Brought to you by Galvanize. Learn more about the way we teach code at [galvanize.com](http://galvanize.com). 3 | 4 | ## Overview 5 | The goal of this brief course is to provide you with a fun introduction to the world of web development, starting with HTML and CSS. 6 | 7 | #### Here's what we'll be doing: 8 | * Setting up our computers for web development 9 | * Overview of basic HTML concepts 10 | * Overview of CSS concepts 11 | * Playing around in the sandbox 12 | 13 | #### Before you begin, a quick gut check: 14 | * This course is for absolute beginners 15 | * Feel free to move ahead 16 | * Help others when you can 17 | * Be patient and nice 18 | * You will get through it! 19 | 20 | #### What web coding is (really)? 21 | Recipes to give to your computer to “cook” up some awesome things for you online 22 | 23 | ## Setting up your computer 24 | (Brace yourself...) 25 | 26 | #### Please set up the following: 27 | * A web browser to see what we're working on as others see it (Recommend Google Chrome: [chrome.google.com] (http://chrome.google.com)) 28 | * A text editor to modify your files (Recommend the Atom text editor: [Atom.io](http://atom.io)) 29 | * Download the tutorial files on this page within the zip file 30 | 31 | #### Download the files for this class: 32 | 1. Go to https://github.com/GalvanizeOpenSource/Learn-To-Code-HTML-CSS 33 | 2. Click on the button on the right-hand side that says "Download ZIP" 34 | 3. Go to your downloads folder and double click on the .zip file to unzip it 35 | 4. IMPORTANT! Leave all the individual files in the downloaded folder (if you would like to move it out of the downloads folder move the entire folder, not individual items) 36 | 5. From Atom: File > open, select the folder and then click "Open" 37 | 6. From Atom: If the file tree does not appear on the left hand View > Toggle Tree View -- this will show you the entire folder within Atom 38 | 7. *Now if you already know some of what we're talking about,* you're all set to poke around in the files -- `index.html` and `CSS/style.css` are the two files we will using. 39 | 40 | Patience! Setting up your computer takes time and can be tricky, especially across platforms. 41 | 42 | Once you're ready, you can move onto the next lesson. 43 | 44 | ## H.T.M.L. - "the building blocks of the internet" 45 | 46 | Hyper Text Markup Language, or HTML, is the most elemental language of the internet. Everything you see within your web browser is an interpretation of HTML in some form of other, and it is essential to learn in all web development. 47 | 48 | ###### The syntax of most HTML is as follows: 49 | * `` - code that wraps around the content of HTML to designate a particular effect, sometimes inherent to the tag. 50 | * `Attributes=""` - code inserted into tags to implement a particular effect that is external to the tag. 51 | * Elements - the combined syntax of tags, attributes, and elements. 52 | 53 | ``` 54 | e.g. Element = content content 55 | ``` 56 | 57 | #### HTML Tags: 58 | Tags are used to mark up the beginning and end of an HTML element. 59 | 60 | Almost everything in HTML needs to start and end with a tag 61 | Everything is wrapped like layers of an onion, `` and `` 62 | - e.g. `
”Hello!”
` 63 | - *Note: not every tag is like this!* 64 | 65 | ###### Common Tags: 66 | - `` designates document as HTML 67 | - `
` notes a block element in the page 68 | - `` anchor, activates a link in the page 69 | - `` contains meta information 70 | - `` contains browser information 71 | - `` notes an inline element 72 | 73 | ###### Irregular Tags: 74 | - `` creates an image in the page 75 | - `
` creates a big break in the page 76 | - `
` creates a horizontal line 77 | - `` connects this to related documents 78 | - `` creates an input field 79 | 80 | #### HTML Attributes: 81 | HTML attributes inform the browser on what to do with a tagged piece of content. 82 | Attributes generally appear as name-value pairs. 83 | ``` 84 |

This is the content of an element with class 'foo'.

85 | ``` 86 | ###### The most common attributes are: 87 | - id="" - id is used on only a single element" 88 | - class="" - class can be used on multiple elements" 89 | - href=”” - hyperlink reference to an internal or external link 90 | - src=”” - source file to an image, video, etc. 91 | - style=”” - add some color, font, margins, etc. 92 | - ^ *There’s a MUCH better way to do this via CSS - more on that later!* 93 | 94 | How do we check elements for whether they're talking to the browser? Use the **inspect element** feature! 95 | 96 | But... how do we make HTML... better? 97 | 98 | ## Overview of CSS 99 | 100 | What Does CSS Stand for? 101 | - Cascading - prioritizing certain values over others 102 | - Style - focusing on layout, colors, fonts, etc. 103 | - Sheet - another name for the file we use here 104 | 105 | The internet used to be ugly. Enter CSS - a consolidated way to make it prettier. 106 | 107 | #### Three primary objects: 108 | - Elements: e.g. h1, div, body, a - default HTML (already reviewed) 109 | - IDs: everything that starts with a “#” 110 | - Classes: everything that starts with a “.” 111 | 112 | #### Syntax of CSS: 113 | ``` 114 | h1 { // this is either an element, class, or ID 115 | font-size: 24px; // syntax is name: value; 116 | font-weight: bold; 117 | color: #000000; // hexadecimal, RGB, etc. 118 | } 119 | ``` 120 | Space doesn’t matter, but “onion” rules apply 121 | 122 | #### What are IDs? 123 | IDs are attributes that are used only on one element ONLY and noted with a “#” symbol in CSS 124 | e.g. 125 | ``` 126 | HTML: 127 | Lee Ngo 128 | 129 | CSS: 130 | #leesName { 131 | color: white; 132 | } 133 | ``` 134 | IDs are used to direct functions to unique elements in the HTML so that there’s no confusion 135 | 136 | *e.g clicking to a specific part of page* 137 | 138 | #### What are Classes? 139 | 140 | Classes are attributes something to multiple elements on a page noted with a “.” symbol in CSS. 141 | ``` 142 | HTML: 143 | Lee Ngo 144 | 145 | CSS: 146 | .ninja { 147 | color: black; margin: 10px; 148 | } 149 | ``` 150 | Classes are used to change or affect multiple items in an HTML document at once 151 | 152 | *e.g. everything with class=”ninja” should have the same attributes* 153 | 154 | In tandem, you can do a lot with HTML & CSS! Let's give it a shot! 155 | 156 | ## LET'S CODE! 157 | 158 | ###### Remember: 159 | - Coding can be hard - be patient! 160 | - Work in pairs! Even the pros do it 161 | - Ask for help - we’re in a school! 162 | 163 | #### Let's get started! 164 | 1. Open up your text editor 165 | 2. Navigate to your repo 166 | 3. Open up the following files 167 | - index.html 168 | - CSS/style.css 169 | 170 | #### Let's change the font! 171 | 1. Navigate to Google Fonts: https://www.google.com/fonts 172 | 2. Find a font you like and click "Add to Collection". 173 | 3. On the bottom right side of your screen click "Use". 174 | 4. On the "Use" page, scroll down to "Number 3" and copy the link tag provided. 175 | 5. Paste that link tag in your index.html file with the new link tag you copied from Google Fonts. 176 | 6. Copy the CSS code under “Number Four.” 177 | 7. Paste that code into your CSS under the body tag. 178 | 8. Save and refresh! 179 | 180 | Did it work! Great! If not open up **Inspect Element** and see what happened. 181 | 182 | ## Play around in the sandbox! 183 | 184 | Try one of the following: 185 | - Change the name of the site to...whatever! 186 | - Change all the navigation links & section headers 187 | - Replacing the images with your own images - locally, online, etc. 188 | - Show what you did with the others! 189 | 190 | # YOU DID IT! YOU'RE NOW A CODER! 191 | 192 | Welcome to the cool kids club. 193 | 194 | #### Want to code more? Check out Galvanize's Full Stack Immersive Program! 195 | 196 | - 24 Week Full-Time Program 197 | - 97% Job Placement Rate within six months 198 | - Average starting salary: $77,000 per annum 199 | - Scholarships available for those who qualify 200 | - Learn more at http://galvanize.com/courses/fullstack/ 201 | 202 | #### Looking for something more flexible? Check out our Evening Workshops! 203 | 204 | - Zero to Web Designer 205 | - Foundations of JavaScript 206 | - Learn more at http://www.galvanize.com/workshops/ 207 | 208 | #### About the Authors 209 | 210 | [Graham McBain](http://linkedin.com/in/grahammcbain) is a graduate of the 3rd cohort of the Galvanzie Full Stack Program and now Evangelist for Galvanize based in the Colorado area. Graham believes that programming is more accessible than people think and is passionate about showing people the path to becoming a developer. 211 | 212 | [Lee Ngo](http://linkedin.com/in/leengo) is an evangelist for Galvanize based in Seattle. Previously he worked for UP Global (now Techstars) and founded his own ed-tech company in Pittsburgh, PA. Lee believes in learning by doing, engaging and sharing, and he teaches code through a combination of visual communication, teamwork, and project-oriented learning. 213 | 214 | You can email him at lee.ngo@galvanize.com for any further questions. 215 | -------------------------------------------------------------------------------- /index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | Learn to Code with Galvanize! 5 | 6 | 7 | 8 | 9 |
10 |
11 |
12 |

This is a title!

13 |

This is a subtitle!

14 |
15 |
16 | 17 | 26 | 27 |
28 | 29 |
30 |

This goes to Link #1

31 |

Can you change the image below?

32 |
33 | 34 |
35 |
36 |
37 | 38 |
39 | 40 |
41 |

This goes to Link #2

42 |

Can you change the link to this image?

43 |
44 | 45 |
46 |
47 |
48 | 49 |
50 |
51 |

This goes to Link #3

52 |

What about putting a video here that links to your favorite site?

53 |
54 | 55 |
56 |
57 |
58 |
59 | 60 | 61 | --------------------------------------------------------------------------------