Pen Settings



CSS Base

Vendor Prefixing

Add External Stylesheets/Pens

Any URLs 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 its URL and the proper URL extension.

+ add another resource


Babel includes JSX processing.

Add External Scripts/Pens

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.

+ add another resource


Add Packages

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.


Save Automatically?

If active, Pens will autosave every 30 seconds after being saved once.

Auto-Updating Preview

If enabled, the preview panel updates automatically as you code. If disabled, use the "Run" button to update.

Format on Save

If enabled, your code will be formatted when you actively save your Pen. Note: your code becomes un-folded during formatting.

Editor Settings

Code Indentation

Want to change your Syntax Highlighting theme, Fonts and more?

Visit your global Editor Settings.


<meta name="viewport" content="width=device-width, initial-scale=1">

<link rel="preconnect" href="">
<link rel="preconnect" href="" crossorigin>
<link href="" rel="stylesheet">

  <h1>Assignment 2 for Week 2</h1>
  <h2><i>By Yizhi Xu 10/8/2021</i></h2>
  <p>I want to introduce some of my <span style="color:#0F93FA;font-weight:bold">favorite.</span> things in a table </p>
  <table border="3">
      <th>My Favourite Animal(s)</th>
      <th>My Favourite Food</th>
      <th>My Favourite Class(es)</th>
      <td style="text-align:center;"> Dog</td>
      <td style="text-align:center;"> Steak</td>
      <td style="text-align:center;"> Journalism </td>

      <td style="text-align:center;">Cat</td>
      <td style="text-align:center;">Ice Cream</td>
      <td style="text-align:center;">Computer</td>
  <p>Next is my <span style="color:#0F93FA;font-weight:bold">special effect</span> photo. </p>
<div class="container">
  <img src="" 
alt="Cat" style="width:100%;">
  <div class="top-left"> Hope You Have A Happy Day!</div>

  <figcaption>Photo by Karina Vorozheeva </figcaption>

<p class="codepen" data-height="300" data-default-tab="html,result" data-slug-hash="NWgJPaX" data-user="Eassy" style="height: 300px; box-sizing: border-box; display: flex; align-items: center; justify-content: center; border: 2px solid; margin: 1em 0; padding: 1em;">
  <span>See the Pen <a href="">
  Untitled</a> by Yizhi (<a href="">@Eassy</a>)
  on <a href="">CodePen</a>.</span>
<script async src=""></script>

<button type="button" onclick="alert('Thanks for watching!')">Click Me!</button>

Enter Name:<input type="text" name="name"/><br/>  



                h1 {
  color: #FFFFFF;
  font-family: 'Open Sans', cursive;
  font-size: 50px;
h2 {
  font-family: 'Open Sans', cursive;
  font-size: 10px;

.container {
  position: relative;
  text-align: center;
  color: #FFFFFF;

table {
  border-collapse: collapse;
  width: 100%;
  border: 2px solid green;
  background-color: #FFFFFF}

tr:hover {background-color: yellow;}

th,td,tr {padding: 
  5px 20px 5px 20px} 

/* Top left text */
.top-left {
  position: absolute;
  top: 100px;
  left: 20px;
  font-size: 40px;

body {background-color: #E6B0AA}