{"componentChunkName":"component---src-templates-blog-post-js","path":"/blog/freecodecamp/frontend/css/fcc-challenge-17-size-your-images/","result":{"data":{"site":{"siteMetadata":{"title":"Be Brav3"}},"markdownRemark":{"id":"4701a219-4b6c-5e10-9c4e-ce159c982240","excerpt":"In Free Code Camp Challenge 17 we need to change the size of the image to 100px in the follow code: css h2 { font-family: Lobster, Monospace; } p { font-size…","html":"<p>In <a href=\"https://www.freecodecamp.com/challenges/size-your-images\">Free Code Camp Challenge 17</a> we need to change the size of the image to 100px in the follow code:</p>\n<p>[css]</p>\n<link href=\"https://fonts.googleapis.com/css?family=Lobster\" rel=\"stylesheet\" type=\"text/css\">\n  \n<style>\n    \n.red-text {\n      \ncolor: red;\n    \n}\n<p>h2 {</p>\n<p>font-family: Lobster, Monospace;</p>\n<p>}</p>\n<p>p {</p>\n<p>font-size: 16px;</p>\n<p>font-family: Monospace;</p>\n<p>}</p>\n</style>\n<h2 class=\"red-text\">CatPhotoApp</h2>\n<img src=\"https://bit.ly/fcc-relaxing-cat\" alt=\"A cute orange cat lying on its back. \">\n<p class=\"red-text\">Kitty ipsum dolor sit amet, shed everywhere shed everywhere stretching attack your ankles chase the red dot, hairball run catnip eat the grass sniff.</p>\n  \n<p class=\"red-text\">Purr jump eat the grass rip the couch scratched sunbathe, shed everywhere rip the couch sleep in the sink fluffy fur catnip scratched.</p>\n  \n[/css]\n<p>The updated code should look like this:</p>\n<p>[css]</p>\n<link href=\"https://fonts.googleapis.com/css?family=Lobster\" rel=\"stylesheet\" type=\"text/css\">\n  \n<style>\n    \n.red-text {\n      \ncolor: red;\n    \n}\n<p>h2 {</p>\n<p>font-family: Lobster, Monospace;</p>\n<p>}</p>\n<p>p {</p>\n<p>font-size: 16px;</p>\n<p>font-family: Monospace;</p>\n<p>}</p>\n<p>.smaller-image {</p>\n<p>width: 100px;</p>\n<p>}</p>\n</style>\n<h2 class=\"red-text\">CatPhotoApp</h2>\n<img class=\"smaller-image\" src=\"https://bit.ly/fcc-relaxing-cat\" alt=\"A cute orange cat lying on its back. \">\n<p class=\"red-text\">Kitty ipsum dolor sit amet, shed everywhere shed everywhere stretching attack your ankles chase the red dot, hairball run catnip eat the grass sniff.</p>\n  \n<p class=\"red-text\">Purr jump eat the grass rip the couch scratched sunbathe, shed everywhere rip the couch sleep in the sink fluffy fur catnip scratched.</p>\n  \n[/css]\n<blockquote>\n<p>CSS has a property called width that controls an element’s width. Just like with fonts, we’ll use px (pixels) to specify the image’s width.</p>\n<p>For example, if we wanted to create a CSS class called larger-image that gave HTML elements a width of 500 pixels, we’d use:</p>\n</blockquote>\n<blockquote>\n<p>[css]</p>\n</blockquote>\n<blockquote>\n<style>\n</blockquote>\n<blockquote>\n<p>.larger-image {</p>\n</blockquote>\n<blockquote>\n<p>width: 500px;</p>\n</blockquote>\n<blockquote>\n<p>}</p>\n</blockquote>\n<blockquote>\n</style>\n</blockquote>\n<blockquote>\n<p>[/css]</p>\n<p>Create a class called smaller-image and use it to resize the image so that it’s only 100 pixels wide.</p>\n<p>Note</p>\n</blockquote>\n<blockquote>\n<p>Due to browser implementation differences, you may need to be at 100% zoom to pass the tests on this challenge.</p>\n</blockquote>","frontmatter":{"title":"FCC Challenge 17: Size your Images","date":"March 07, 2016","description":null}}},"pageContext":{"slug":"/blog/freecodecamp/frontend/css/fcc-challenge-17-size-your-images/","previous":{"fields":{"slug":"/blog/freecodecamp/frontend/html/fcc-challenge-16-add-images-to-your-website/"},"frontmatter":{"title":"FCC Challenge 16: Add Images to your Website"}},"next":{"fields":{"slug":"/blog/freecodecamp/frontend/css/fcc-challenge-18-add-borders-around-your-elements/"},"frontmatter":{"title":"FCC Challenge 18: Add Borders Around Your Elements"}}}}}