A collection of 7 posts

Use any TTF font CSS

Web css ttf font declare use

If you want to use a TTF font (standard font file) on your website you need to start by defining your font in CSS: @font-face { font-family: typewriterFont; src: url(../fonts/typewriter.ttf); } body { font-family: typewriterFont; } font-family defines the name of the font "typewriterFont&

Add CSS stitched border effect

css stitched border effect

Add a stitched border to a div in CSS: .stitched { padding: 20px; margin: 10px; background: #6fa348; color: #fff; font-size: 21px; font-weight: bold; line-height: 1.3em; border: 2px dashed #fff; border-radius: 10px; box-shadow: 0 0 0 4px #ff0030, 2px 1px 6px 4px rgba(10, 10,

Lesson 2 - Basic HTML elements

css html html elements

HTML Headings HTML is comprised of 6 heading sizes: h1 to h6 h1 - Largest heading h2 - Large heading h3 - Medium heading h4 - Small heading h5 - Smaller heading h6 - Smallest heading HTML Paragraphs Paragraphs are created using the p

Vertically align image in div

css vertical align image

To align an image vertically in a div you need to add the following styles on the element surrounding the image: display: inline-block vertical-align: middle The following style should also be added to the image: vertical-align: middle Example pen: See the Pen