Pen Settings

HTML

CSS

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

JavaScript

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

Packages

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.

Behavior

Auto Save

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.

HTML

              
                <div class="container">
<h1>Cara Membuat Turn On/Off Lights Video di Blog</h1>
<span>
<p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Phasellus sed pretium elit, id varius eros. Phasellus rutrum ligula risus, eget ornare quam faucibus ut. Pellentesque cursus porta ligula, eget pellentesque erat feugiat vestibulum. In odio ante, gravida nec arcu a, luctus euismod erat. Nam eu mattis nisl. Duis porta sapien at dapibus porttitor. Duis ullamcorper lectus a vehicula auctor. Vestibulum in pretium nibh. Maecenas mi dui, sollicitudin ut sem eu, congue mollis lacus.</p>
</br> 
<div id="stopkontak">
  <a class="lampunyala" href="javascript:void(0);">Turn Off</a>
  <div style="text-align:center">
<object data="//www.youtube.com/embed/y9bic_wp5ro" height="315" width="560"></object>
</div> </div>
 </br>
<p>Praesent fermentum eros quam, sit amet facilisis neque auctor sagittis. Etiam lacinia purus quis ex commodo, nec faucibus enim lobortis. Fusce libero lacus, porta id urna vel, viverra placerat eros. In commodo sed libero ut interdum. In iaculis augue eu diam varius, quis venenatis ipsum placerat. Duis ac dignissim lectus. Donec porttitor at sem non condimentum. Suspendisse potenti. Etiam semper ex eu risus dictum vulputate. Aenean mollis dolor tellus, rutrum egestas nisi congue ac.</p>
</br>
<p>Fusce et sem vel nulla viverra suscipit. Praesent suscipit sem luctus, fringilla turpis non, scelerisque risus. Nulla sed venenatis purus. Ut suscipit luctus enim, a iaculis ipsum congue a. Etiam sed quam purus. Phasellus vel massa maximus, mollis neque sit amet, fermentum urna. Donec tincidunt augue ut posuere blandit. Aliquam massa nibh, tristique at ex sed, sagittis tincidunt nisi. Maecenas sollicitudin dapibus imperdiet. Quisque odio felis, ullamcorper consequat sapien nec, gravida dapibus sem.</p>
<div id='settinganlampu'/>
</span>
</div>
              
            
!

CSS

              
                @import url(https://fonts.googleapis.com/css?family=Open+Sans:400,700);
body {
  background: #f1f1f1 none repeat scroll top left;
  font-family: 'Open Sans', sans-serif;
  margin: 0;
  padding: 0;
  position: relative;
  line-height: normal;
}

a,
a:visited {
  color: #555;
  outline: none;
  text-decoration: none;
}

a:hover,
a:focus,
a:visited:hover {
  text-decoration: none;
}

.container {
  max-width: 768px;
  margin: 1% auto;
  padding: 30px;
  background: #fff;
  color: #95a5a6;
  font-family: 'Open Sans', sans-serif;
  font-size: 1em;
  line-height: normal;
}

.container h1,
.container h2 {
  display: block;
  text-align: center;
  margin-bottom: 30px;
  font-size: 2em;
  font-weight: 700;
  color: #336699;
}

.container h2 {
  margin-top: 30px;
}
.container input {
  margin: 30px auto;
  text-align:center;
  display:table;
  padding:10px 15px;
  font-size:16px;
  background:#8092e9;
  color:#fff;
  border:0;
  border-radius:1px;
  cursor:pointer;
  transition:all .3s
}
.container input:hover,.container input:active {
  background:#3c5aeb;
  color:#fff;
  outline:none
}

/* Turn On Off the Lights by Caramanual.com */
#stopkontak {
position:relative;
z-index:999;
}
.lampunyala {
float: right;
background: #328bdd;
display: inline-block;
color: #fff;
border-radius: 3px;
padding: 10px 15px;
}
.lampunyala:hover {
background-color: #1f72be;
}
.lampunyala:before{content: "\f0eb";
color:#000;
font-family: FontAwesome;
font-style: normal;
font-weight: normal;
text-decoration: inherit;
margin-right: 10px;
color:#ffff00;}
.lampumati {
background: #328bdd;
float: right;
position:relative;
display: inline-block;
color: #fff;
border-radius: 3px;
padding: 10px 15px;
}
.lampumati:hover {
background-color: #1f72be;
}
.lampumati:before{content: "\f0eb";
font-family: FontAwesome;
font-style: normal;
font-weight: normal;
text-decoration: inherit;
margin-right: 10px;
color:#000;}
#settinganlampu {
background:#000;
opacity:0.9;
filter:alpha(opacity=90);
position:absolute;
left:0;
top:0;
width:100%;
z-index:997;
}
              
            
!

JS

              
                $(document).ready(function(){
$("#settinganlampu").css("height", $(document).height()).hide();
$(".lampunyala").click(function(){
$("#settinganlampu").toggle();
if ($("#settinganlampu").is(":hidden"))
$(this).html("Turn Off").removeClass("lampumati");
else
$(this).html("Turn On").addClass("lampumati");
});
});
              
            
!
999px

Console