HTML preprocessors can make writing HTML more powerful or convenient. For instance, Markdown is designed to be easier to write and read for text documents and you could write a loop in Pug.
In CodePen, whatever you write in the HTML editor is what goes within the <body>
tags in a basic HTML5 template. So you don't have access to higher-up elements like the <html>
tag. If you want to add classes there that can affect the whole document, this is the place to do it.
In CodePen, whatever you write in the HTML editor is what goes within the <body>
tags in a basic HTML5 template. If you need things in the <head>
of the document, put that code here.
The resource you are linking to is using the 'http' protocol, which may not work when the browser is using https.
CSS preprocessors help make authoring CSS easier. All of them offer things like variables and mixins to provide convenient abstractions.
It's a common practice to apply CSS to a page that styles elements such that they are consistent across all browsers. We offer two of the most popular choices: normalize.css and a reset. Or, choose Neither and nothing will be applied.
To get the best cross-browser support, it is a common practice to apply vendor prefixes to CSS properties and values that require them to work. For instance -webkit-
or -moz-
.
We offer two popular choices: Autoprefixer (which processes your CSS server-side) and -prefix-free (which applies prefixes via a script, client-side).
Any URL's added here will be added as <link>
s in order, and before the CSS in the editor. You can use the CSS from another Pen by using it's URL and the proper URL extention.
You can apply CSS to your Pen from any stylesheet on the web. Just put a URL to it here and we'll apply it, in the order you have them, before the CSS in the Pen itself.
You can also link to another Pen here (use the .css
URL Extension) and we'll pull the CSS from that Pen and include it. If it's using a matching preprocessor, use the appropriate URL Extension and we'll combine the code before preprocessing, so you can use the linked Pen as a true dependency.
JavaScript preprocessors can help make authoring JavaScript easier and more convenient.
Babel includes JSX processing.
Any URL's added here will be added as <script>
s in order, and run before the JavaScript in the editor. You can use the URL of any other Pen and it will include the JavaScript from that Pen.
You can apply a script from anywhere on the web to your Pen. Just put a URL to it here and we'll add it, in the order you have them, before the JavaScript in the Pen itself.
If the script you link to has the file extension of a preprocessor, we'll attempt to process it before applying.
You can also link to another Pen here, and we'll pull the JavaScript from that Pen and include it. If it's using a matching preprocessor, we'll combine the code before preprocessing, so you can use the linked Pen as a true dependency.
Search for and use JavaScript packages from npm here. By selecting a package, an import
statement will be added to the top of the JavaScript editor for this package.
Using packages here is powered by Skypack, which makes packages from npm not only available on a CDN, but prepares them for native JavaScript ES6 import
usage.
All packages are different, so refer to their docs for how they work.
If you're using React / ReactDOM, make sure to turn on Babel for the JSX processing.
If active, Pens will autosave every 30 seconds after being saved once.
If enabled, the preview panel updates automatically as you code. If disabled, use the "Run" button to update.
If enabled, your code will be formatted when you actively save your Pen. Note: your code becomes un-folded during formatting.
Visit your global Editor Settings.
<div id="main">
<div class="container">
<div class="jumbotron">
<div class="row">
<div class="col-xs-12">
<h1 id="title"><strong>Jim Morrison</strong></h1>
<h2 class="text-center"><em>The doors of perception</em></h2>
<div id="img-div">
<div class="thumbnail">
<img id="image" src="https://www.billboard.com/files/media/the-doors-1960s-billboard-1548.jpg" alt= "Jim and his band">
<div id="img-caption">Jim Morrison first from the left, photo in studio with his band "The DOORS"</div>
</div>
</div>
<div id="tribute-info">
<div class="col-sx-12 col-sm-10 col-sm-offset-1 col-md-8 col-md-offset-2">
<h3>Here's few dates of Morrison's life</h3>
<ul>
<li><strong>1943</strong> James Douglas Morrison (December 8, 1943 – July 3, 1971) was an American singer, songwriter, and poet, best remembered as the lead singer of the Doors. Due to his poetic lyrics, distinctive voice, wild personality, performances, and the dramatic circumstances surrounding his life and early death, Morrison is regarded by both music critics and fans as one of the most iconic and influential frontmen in rock music history.</li>
<li><strong>1964–65</strong> In January 1964, Morrison moved to Los Angeles to attend the University of California, Los Angeles (UCLA). Shortly thereafter on August 2, 1964, Morrison's father, George Stephen Morrison, commanded a carrier division of the United States fleet during the Gulf of Tonkin Incident, which resulted in the United States' rapid escalation of the Vietnam War. At UCLA, Morrison enrolled in Jack Hirschman's class on Antonin Artaud in the Comparative Literature program within the UCLA English Department. Artaud's brand of surrealist theatre had a profound impact on Morrison's dark poetic sensibility of cinematic theatricality. Morrison completed his undergraduate degree at UCLA's film school within the Theater Arts department of the College of Fine Arts in 1965.</li>
<li><strong>1965</strong> Morrison co-founded the Doors during the summer of 1965 in Venice, California. The band spent two years in obscurity until shooting to prominence with their #1 single in the United States, "Light My Fire", taken from their self-titled debut album. Morrison recorded a total of six studio albums with the Doors, all of which sold well and received critical acclaim.</li>
<li><strong>1971</strong> Morrison joined Pamela Courson in Paris in March 1971, at an apartment he had rented on the rue Beautreillis (in the 4th arrondissement of Paris on the Right Bank). In letters he described going for long walks through the city, alone. During this time, he shaved his beard and lost some of the weight he had gained in the previous months. He died on July 3, 1971 at age 27. He was found by Courson in a bathtub at his apartment. The official cause of death was listed as heart failure,better source needed although no autopsy was performed, as it was not required by French law. His death was two years to the day after the death of Rolling Stones guitarist Brian Jones, and approximately nine months after the deaths of Jimi Hendrix and Janis Joplin.</li>
</ul>
<blockquote>
<p>People are afraid of themselves, of their own reality; their feelings most of all. People talk about how great love is, but that's bullshit. Feelings are disturbing. People are taught that pain is evil and dangerous. How can they deal with love if they are afraid to feel. Pain is meant to wake us up. People try to hide pain but they're wrong. Pain is something to carry, like a radio. You feel your strength in the experience of pain. It's all in how you carry it.</p>
<footer><cite>Jim Morrison</cite></footer>
</blockquote>
<h3>More about Jim here <a id="tribute-link" href="https://en.wikipedia.org/wiki/Jim_Morrison" target="_blank">Wikipedia</a>.</h3>
</div>
</div>
</div>
</div>
</div>
<footer class="text-center">
<hr><p>First Training by <a href="https://codepen.io/dotpot420/" target="_blank">DotPot420</a></p></footer>
</div>
</div>
body {
margin-top: 60px;
}
.jumbotron{
background-color: #dee6f4;
}
h1,blockquote {
font-family:'Playfair Display';
}
h2,h3,li{
font-family:"PT Sans";
}
#title {
text-align: center;
}
#img-caption {
text-align: center;
}
h3 {
text-align: center;
}
strong {
font-size: 1.2em;
}
li {
margin-bottom: 2%;
}
Also see: Tab Triggers