Skip to content

Instantly share code, notes, and snippets.

@jsolid
jsolid / moving-fonts.html
Created September 21, 2012 01:35
Move fonts in parallax effect
<!doctype html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<title>Moving Fonts</title>
<script type="text/javascript" src="https://ajax.googleapis.com/ajax/libs/jquery/1.7.1/jquery.min.js"></script>
<script type="text/javascript" src="plax.js"></script>
<style type="text/css">
* {
padding: 0;
@jsolid
jsolid / form-control.js
Created September 17, 2012 04:46
Display confirmation dialog before exiting/refreshing current page
var processDialog = new YAHOO.widget.Dialog('procDialog', {
width: '400px',
height: '350px',
underlay: 'shadow',
visible: false,
modal: true,
});
window.onbeforeunload = (function() {
if ( processDialog.cfg.getProperty('visible') &&
@jsolid
jsolid / gradient-button.css
Created September 7, 2012 06:13
Gradient button
.button {
display: inline-block;
outline: none;
cursor: pointer;
text-align: center;
text-decoration: none;
font: 14px/100% Arial, Helvetica, sans-serif;
padding: .5em 2em .55em; /* Change values for different sizes */
text-shadow: 0 1px 1px rgba(0,0,0,.3);
-webkit-border-radius: .5em;
@jsolid
jsolid / hide-show-div-when-element-clicked.html
Created September 7, 2012 00:38
Hide/Show DIV when element is clicked
<form id="sForm" name="sForm" method="POST">
<!-- DIV containing textfield, always display -->
<div id="inside" name="inside" class="inside">
<input type="text" id="searchText" name="searchText" maxlength="25" placeholder="search for games" autocomplete="off" tabindex="1" style="z-index:500" />
</div>
<!-- DIV of wrapping block -->
<div id="outside" name="outside" class="outside hidden">
<div class="hd">
<div id="closeBtn" name="closeBtn" class="right btnClose">X</div>