×

Save Your Code

If you click the save button, your code will be saved, and you get an URL you can share with others.

By clicking the "Save" button you agree to our terms and conditions.

Report Error

×

Save to Google Drive

If you have a Google account, you can save this code to your Google Drive.

Google will ask you to confirm Google Drive access.

×

Open from Google Drive

If you have saved a file to Google Drive, you can open it here:

Result Size: 625 x 571
x
 
<!DOCTYPE html>
<html>
<title>W3.CSS</title>
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="stylesheet" href="4/w3.css">
<body class="w3-container">
<h2>Code Containers</h2>
<p>The w3-code class create code containers to highlight HTML, JavaScript and CSS code.</p>
<div class="w3-panel w3-card w3-light-grey"> 
<h4>HTML Example</h4>
<div class="w3-code htmlHigh notranslate">
&lt;!DOCTYPE html&gt;<br>&lt;html&gt;<br>
&lt;title&gt;HTML Tutorial&lt;/title&gt;<br>
&lt;body&gt;<br><br>
&lt;h1&gt;This is a heading&lt;/h1&gt;<br>
&lt;p&gt;This is a paragraph.&lt;/p&gt;<br><br>
&lt;/body&gt;<br>
&lt;/html&gt;
</div>
</div>
<div class="w3-panel w3-card w3-light-grey"> 
<h4>CSS Example</h4>
<div class="w3-code cssHigh notranslate">
body {<br>
  background-color: #d0e4fe;<br>}<br><br>
h1 {<br>
  color: orange;<br>
  text-align: center;<br>}<br><br>
p {<br>
  font-family: "Times New Roman";<br>
  font-size: 20px;<br>
}
</div>
</div>
<div class="w3-panel w3-card w3-light-grey"> 
<h4>JavaScript Example</h4>
<div class="w3-code jsHigh notranslate">
var x = 5;        // assign the value 5 to x<br>
var y = 2;        // assign the value 2 to y<br>
var z = x + y;    // assign the value
</div>
</div>
×

Report a Problem: