Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- /* 1. ARCHIVO index.html (estructura HTML5 - LENGUAJE DE MARCADO DE HIPERTEXTO) */
- <!DOCTYPE html>
- <html lang="es">
- <head>
- <meta charset="utf-8">
- <meta name="description" content="Ejemplo de HTML5 con CSS3">
- <meta name="keywords" content="HTML5, CSS3, JavaScript">
- <title>HTML5 y CSS3</title>
- <link rel="stylesheet" href="estilos.css">
- </head>
- <body>
- <div id="agrupar">
- <header id="cabecera">
- <h1>Este es el título principal del sitio web</h1>
- </header>
- <nav id="menu">
- <ul>
- <li>principal</li>
- <li>fotos</li>
- <li>videos</li>
- <li>contacto</li>
- </ul>
- </nav>
- <section id="seccion">
- <article>
- <header>
- <hgroup>
- <h1>Título del mensaje uno</h1>
- <h2>Subtítulo del mensaje uno</h2>
- </hgroup>
- <time datetime="2011-12-10" pubdate>publicado 10-11-2013</time>
- </header>
- Este es el texto de mi primer mensaje
- <figure>
- <img src="http://minkbooks.com/content/myimage.jpg">
- <figcaption>
- Esta es la imagen del primer mensaje
- </figcaption>
- </figure>
- <footer>
- <p>comentarios (0)</p>
- </footer>
- </article>
- <article>
- <header>
- <hgroup>
- <h1>Título del mensaje dos</h1>
- <h2>Subtítulo del mensaje dos</h2>
- </hgroup>
- <time datetime="2011-12-15" pubdate>publicado 05-11-2013</time>
- </header>
- Este es el texto de mi segundo mensaje
- <footer>
- <p>comentarios (0)</p>
- </footer>
- </article>
- </section>
- <aside id="columna">
- <blockquote>Mensaje número uno</blockquote>
- <blockquote>Mensaje número dos</blockquote>
- </aside>
- <footer id="pie">
- © Script BC Todos los Derechos Reservados 2013
- </footer>
- </div>
- </body>
- </html>
- 2. ARCHIVO estilos.css (CSS3 - HOJA DE ESTILOS PARA APLICAR AL ARCHIVO index.html)
- * {
- margin: 0px;
- padding: 0px;
- }
- header, section, footer, aside, nav, article, figure, figcaption,
- hgroup{
- display: block;
- }
- h1 {
- font: bold 20px verdana, sans-serif;
- }
- h2 {
- font: bold 14px verdana, sans-serif;
- }
- body {
- text-align: center;
- }
- #agrupar {
- width: 90%; /*Ancho del contenedor*/
- margin: 15px auto; /*auto= margen superior e inferior*/
- text-align: left; /*text-align es hereditaria por lo tanto
- debemos regresarla a su configuración normal*/
- }
- #cabecera {
- background: #FFFBB9;
- border: 1px solid #999999;
- padding: 20px;
- }
- #menu {
- background: #CCCCCC;
- padding: 5px 15px;
- }
- #menu li {
- display: inline-block;
- list-style: none;
- padding: 5px;
- font: bold 14px verdana, sans-serif;
- }
- #seccion {
- width: 70%;
- margin: 20px;
- float: left;
- }
- #columna {
- width: 20%;
- margin: 20px 0px;
- float: left;
- padding: 20px;
- background: #CCCCCC;
- }
- #pie {
- clear: both;
- background: #CCCCCC;
- text-align: center;
- padding: 20px;
- border-top: 2px solid #999999;
- }
- article {
- background: #FFFBCC;
- border: 1px solid #999999;
- padding: 20px;
- margin-bottom: 15px;
- }
- article footer {
- text-align: right;
- }
- time {
- color: #999999;
- }
- figcaption {
- font: italic 14px verdana, sans-serif;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement