Pen Settings

HTML

CSS

CSS Base

Vendor Prefixing

Add External Stylesheets/Pens

Any URL's added here will be added as <link>s in order, and before the CSS in the editor. If you link to another Pen, it will include the CSS from that Pen. If the preprocessor matches, it will attempt to combine them before processing.

+ 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

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.

HTML

              
                	<!-- Ears -->
<script src="//ajax.googleapis.com/ajax/libs/jquery/1.9.1/jquery.min.js"></script>


<div class="ears_container">
  
  <div class="button_ears">
	<div class="ear_img">
	    <img align="middle" alt="" src="http://www.roboforex.com/files/filemanager/image/products-panel/contestfx_button.png" style="width: 23px; height: 71px;">
	</div>
	<div class="s_panel" style="left: -500px;">
	    <a href="#" target="_blank">
		<span>
		    <span><img alt="" src="http://www.roboforex.com/files/filemanager/image3/ears/copy-web-min.png"></span> 
		    <span>Contest project of a new type: real prizes in exciting competitions on demo accounts. </span> 
		    <span><img alt="" src="http://www.roboforex.com/files/filemanager/image/products-panel/arrow-grey.png"> </span>
		</span> 
	    </a>
	</div>
    </div>

 
 
<div class="button_ears copyfx">
	<div class="ear_img">
	    <img alt="" src="http://www.roboforex.com/files/filemanager/image/products-panel/copyfx_button.png" style="width: 23px; height: 71px;">
	</div>
	<div class="s_panel copyfx" style="left: -500px;">
	    <a href="#" target="blank">
		<span>
		    <span><img alt="" src="http://www.roboforex.com/files/filemanager/image3/ears/copy-web-min.png"></span> 
		    <span>Invest in a new way: system of copying transactions, tansfer accounts into management</span>
		    <span><img alt="" src="http://www.roboforex.com/files/filemanager/image/products-panel/arrow-grey.png"> </span>
		</span> 
	    </a>
	</div>
    </div>

  
<div class="button_ears copyfx" style="height: 94px;">
  <div class="ear_img" style="height: 94px;">
    <img alt="" src="http://www.roboforex.com/files/filemanager/image3/ears/copy.png" style="width: 28px; height: 94px;border-radius: 0 5px 5px 0;" /></div>
  <div class="s_panel copyfx" style="height: 94px; background: #2D486F; top: -98px;">
<a href="#" style="text-decoration: none; display: block;" target="_blank">
  <span style="padding-left: 15px; height: 96px;"><span style="height: 96px;"><img alt="" src="http://www.roboforex.com/files/filemanager/image3/ears/copy-web-min.png" style="width: 40px;height: 40px; max-width:none;" /></span> <span style="color: #ffffff;text-shadow: none;height: 96px;">Investasi menguntungkan di pasar Forex: Menyalin transaksi Trader sukses</span> <span style="
    height: 96px;"><img alt="" src="http://www.roboforex.com/files/filemanager/image/products-panel/arrow-grey.png" /> </span> </span> </a></div>
</div>

 
<div class="button_ears copyfx" style="height: 94px;">
  <div class="ear_img">
    <img alt="" src="http://www.roboforex.com/files/filemanager/image3/ears/ramm.png" style="width: 28px; height: 94px;border-radius: 0 5px 5px 0;" /></div>
  <div class="s_panel copyfx" style="height: 94px; background: #64BDFF; top: -98px;">
    <a href="#" style="text-decoration: none; display: block;" target="_blank">
      <span style="padding-left: 15px; height: 96px;"><span style="height: 96px;"><img alt="" src="http://www.roboforex.com/files/filemanager/image3/ears/copy-web-min.png" style="width: 40px;height: 40px; max-width:none;" /></span> <span style="color: #ffffff;text-shadow: none;height: 96px;">Pengembangan investasi baru di Forex: meningkatkan kendali terhadap risiko dan alokasi keuntungan yang proporsional</span> <span style="
    height: 96px;"><img alt="" src="http://www.roboforex.com/files/filemanager/image/products-panel/arrow-grey.png" /> </span> </span> </a></div>
</div>
  
  
<div class="button_ears" style="height: 94px;">
	<div class="ear_img" style="height: 94px;">
		<img alt="" src="http://www.roboforex.ru/files/filemanager/image3/ears/stocks_ear.png" style="width: 28px; height: 94px;border-radius: 0 5px 5px 0;" /></div>
	<div class="s_panel copyfx" style="height: 94px; background: #1a7ed6; top: -98px;">
		<a href="#" style="text-decoration: none; display: block;" target="_blank">
      <span style="padding-left: 15px; height: 96px;"><span style="height: 96px;"><img alt="" src="http://www.roboforex.com/files/filemanager/image3/ears/copy-web-min.png" style="width: 40px;height: 40px; max-width:none;" /></span> <span style="color: #ffffff;text-shadow: none;height: 96px;">Akses langsung ke pasar saham nyata mulai dari <nobr>100 USD</nobr> dengan lebih dari 8,000 Saham dan ETF</span> <span style="
    height: 96px;"><img alt="" src="http://www.roboforex.com/files/filemanager/image/products-panel/arrow-grey.png" /> </span> </span> </a></div>
</div>
  
  </div><!-- -->




<script type="text/javascript">
    var ears_container = $('.ears_container');
    var floating_question = $('.floating-question');
    var wrapper = $('#wrapper'); 
    var window_width = $(window).width();

    $(window).load(function () {

	if ($('.content__holder .container').length) {
	    wrapper = $('.content__holder .container'); 
	} else if ($('#wrap .container').length) {
	    wrapper = $('#wrap .container'); 
	}

	var total_width = parseInt((ears_container.width() * 2) + wrapper.width());

	calculateBlockOffset();
	changeSideButtonsVisibility(window_width, total_width);

	if (window_width > total_width) {
	    $('.ears_container').animate({
		'left': '-1px'
	    }, 'fast');
	}
    });

    $(window).resize(function () {
	calculateBlockOffset();

	window_width = $(window).width();
	total_width = parseInt((ears_container.width() * 2) + wrapper.width());
	changeSideButtonsVisibility(window_width, total_width);
    });

    $(".button_ears:last-child").addClass('last');

    $(".button_ears").click(function (e) {
	var obj = $(this).find('.s_panel');

	if (!$(this).hasClass('open')) {
	    obj.stop(true, true).animate({
		left: '42px'
	    }, 500);
	    $(this).addClass('open');
	} else {
	    obj.stop(true, true).animate({
		left: '-500px'
	    }, 500);
	    $(this).removeClass('open');
	}
	e.stopPropagation();
    }
    ).hover(
	    function () {
		var timer = $(this).data('timer');
		if (timer)
		    clearTimeout(timer);
	    },
	    function () {
		var obj = $(this);
		obj.data('timer', setTimeout(function () {
		    if (obj.hasClass('open')) {
			obj.children('.s_panel').stop(true, true).animate({
			    left: '-500px'
			}, 500)
			obj.removeClass('open');
		    }
		}, 1500));
	    }
    );

    $('html').click(function () {
	$('.button_ears.open .s_panel').stop(true, true).animate({
	    left: '-500px'
	}, 500);
	$('.button_ears.open').removeClass('open');
    });

    function calculateBlockOffset() {

	var window_height = $(window).height();
	var block_height = $('.ears_container').height();
	var offset = parseInt(window_height - block_height) / 2;

	$('.ears_container').css({
	    'top': window_height > block_height ? offset : '0'
	});
    }

    function changeSideButtonsVisibility(window_width, total_width) {

	if (window_width <= total_width) {
	    ears_container.animate({'left': '-40px'}, 50, 'linear');
	    floating_question.animate({'right': '-32px'}, 50, 'linear');
	} else {
	    ears_container.animate({'left': '-1px'}, 50, 'linear');
	    floating_question.animate({'right': '-1px'}, 50, 'linear');
	}
    }
</script>

<!-- /Ears -->

              
            
!

CSS

              
                /* Product Panel */
.ears_container a {
    text-decoration: none;
}
.ears_container {
    position: fixed;
    top: 160px;
    left: -30px;
    padding: 0px;
    margin: 0px;
    z-index:61;
}
.ears_container.panel_fixed {
    position: absolute;
}
.button_ears {
    cursor: pointer;
    border:1px solid #DFE7EA;
    width: 28px;
    text-align: center;
    -webkit-transition-duration: 0.3s;
    -moz-transition-duration: 0.3s;
    -o-transition-duration: 0.3s;
    transition-duration: 0.3s;
    -webkit-border-radius: 0 5px 5px 0;
    -moz-border-radius: 0 5px 5px 0;
    border-radius: 0 5px 5px 0;
    padding: 0px;
    margin-bottom: 5px;
    background-color: #fafbfc;
}
.panel_container {
    position: relative;
}
.s_panel {
    color:#317CA3;
    position: relative;
    top:-80px;
    left: -402px;
    width: 400px;
    padding: 0px 0 0 0;
    border:1px solid #DFE7EA;
    -webkit-border-radius: 5px;
    -moz-border-radius: 5px;
    border-radius: 5px;
    background-color: #fafbfc;
}
.s_panel,
.ear_img,
.button_ears,
.s_panel span {
    height: 80px;
}
.ear_img,
.s_panel span {
    display: table-cell; vertical-align: middle;
    margin: 0px;
    padding: 0px;
    text-align: left;
    font-weight: 500px;
}
.s_panel span {
    padding-left: 5px;
    padding-right:5px;
}
.button_ears .s_panel span { color: #387aa0; text-shadow: 1px 1px 0px #fff; }
.s_panel.copyfx span,
.s_panel.copyfx a { color:#FFF; text-shadow: 0px 0px 0px; }
.button_ears.copyfx,
.s_panel.copyfx {
    background-color: #317CA3;
    color:#FFF;
}
.button_ears.cy,
.cy .s_panel {
    background: rgb(188,201,210);
    background: url(data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiA/Pgo8c3ZnIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgd2lkdGg9IjEwMCUiIGhlaWdodD0iMTAwJSIgdmlld0JveD0iMCAwIDEgMSIgcHJlc2VydmVBc3BlY3RSYXRpbz0ibm9uZSI+CiAgPGxpbmVhckdyYWRpZW50IGlkPSJncmFkLXVjZ2ctZ2VuZXJhdGVkIiBncmFkaWVudFVuaXRzPSJ1c2VyU3BhY2VPblVzZSIgeDE9IjAlIiB5MT0iMCUiIHgyPSIwJSIgeTI9IjEwMCUiPgogICAgPHN0b3Agb2Zmc2V0PSIwJSIgc3RvcC1jb2xvcj0iI2JjYzlkMiIgc3RvcC1vcGFjaXR5PSIxIi8+CiAgICA8c3RvcCBvZmZzZXQ9IjEwMCUiIHN0b3AtY29sb3I9IiNmZmZmZmYiIHN0b3Atb3BhY2l0eT0iMSIvPgogIDwvbGluZWFyR3JhZGllbnQ+CiAgPHJlY3QgeD0iMCIgeT0iMCIgd2lkdGg9IjEiIGhlaWdodD0iMSIgZmlsbD0idXJsKCNncmFkLXVjZ2ctZ2VuZXJhdGVkKSIgLz4KPC9zdmc+);
    background: -moz-linear-gradient(top,  rgba(188,201,210,1) 0%, rgba(255,255,255,1) 100%);
    background: -webkit-gradient(linear, left top, left bottom, color-stop(0%,rgba(188,201,210,1)), color-stop(100%,rgba(255,255,255,1)));
    background: -webkit-linear-gradient(top,  rgba(188,201,210,1) 0%,rgba(255,255,255,1) 100%);
    background: -o-linear-gradient(top,  rgba(188,201,210,1) 0%,rgba(255,255,255,1) 100%);
    background: -ms-linear-gradient(top,  rgba(188,201,210,1) 0%,rgba(255,255,255,1) 100%);
    background: linear-gradient(to bottom,  rgba(188,201,210,1) 0%,rgba(255,255,255,1) 100%);
    filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#bcc9d2', endColorstr='#ffffff',GradientType=0 );
}

.button_ears.option .s_panel,
.button_ears.option .ear_img,
.button_ears.option,
.button_ears.option .s_panel span {	height: 110px; }

.button_ears.option .s_panel { top:-110px; }
.button_ears.cy .s_panel,
.button_ears.cy .ear_img,
.button_ears.cy,
.button_ears.cy .s_panel span {	height: 156px; }

.button_ears.cy .s_panel { top: -156px; }

.newsdj_copyright {
    margin-bottom: 10px;
}

              
            
!

JS

              
                
              
            
!
999px

Console