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

              
                <link rel="icon" href="https://i1.wp.com/www.mstoic.com/wp-content/uploads/2015/08/cropped-favicon.png?fit=32%2C32&#038;ssl=1" sizes="32x32" />
<link rel="icon" href="https://i1.wp.com/www.mstoic.com/wp-content/uploads/2015/08/cropped-favicon.png?fit=192%2C192&#038;ssl=1" sizes="192x192" />
<link rel="apple-touch-icon-precomposed" href="https://i1.wp.com/www.mstoic.com/wp-content/uploads/2015/08/cropped-favicon.png?fit=180%2C180&#038;ssl=1" />
<meta name="msapplication-TileImage" content="https://i1.wp.com/www.mstoic.com/wp-content/uploads/2015/08/cropped-favicon.png?fit=270%2C270&#038;ssl=1" />

<!-- Latest compiled and minified CSS -->
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css">

<script defer src="https://use.fontawesome.com/releases/v5.0.6/js/all.js"></script>

<link href="https://fonts.googleapis.com/css?family=Bree+Serif|Montserrat|PT+Sans|Pacifico|Raleway|Roboto+Slab|Slabo+27px" rel="stylesheet">

<h3 class="name"></h3>
<h4 class="wishes">Wishes You</h4>
<h3 class="happy-holi">Happy Holi</h3>
<h4 class="advance">In Advance</h4>

<h3 id="getting-started"></h3>

<div class="container">
  <h2>Send Your Greeting</h2>
  <form class="form-inline" action="/action_page.php">
    <div class="form-group">
      <label for="name">Name:</label>
      <input type="text" class="form-control form_name" id="name" placeholder="Your name" name="name">
    </div>
<!--     <button type="button" class="share btn btn-default">Share</button> -->
	  <button type="button" class="whatsapp w3_whatsapp_btn w3_whatsapp_btn_large"><i class="fab fa-whatsapp"></i> WhatsApp</button>
  </form>
</div>
              
            
!

CSS

              
                body {
	background: url("https://image.ibb.co/n3dq37/8629525424_72fe9277bd_o.jpg") no-repeat center center fixed; 
  -webkit-background-size: cover;
  -moz-background-size: cover;
  -o-background-size: cover;
  background-size: cover;
}

body {
	font-family: 'Raleway', sans-serif !important;
	//font-family: 'Roboto Slab', serif !important;
	//font-family: 'Bree Serif', serif !important;
	//font-family: 'Slabo 27px', serif;
	//font-family: 'Montserrat', sans-serif;
	//font-family: 'PT Sans', sans-serif;
	color: white;
	text-align: center;
	text-shadow: 2px 0px 2px rgba(150, 150, 150, 1);
}

h3 {
	font-size: 4em !important;
	margin: .2em auto !important;
	font-weight: bold;
}
h4 {
	font-size: 2.5em !important;
	margin: 0 auto !important;
	font-weight: bold !important;
}

.name {
	color: #03A9F4;
	color: #FFEB3B;
	color: #E91E63;
	color: #FF4081;
	text-shadow: 3px 3px 4px rgba(255, 255, 255, 1);
	text-shadow: 3px 3px 4px rgba(0, 0, 0, 1);
}
.wishes {
	color: #FFF176;
	//color: #00897B;
	text-shadow: 3px 3px 4px rgba(0, 0, 0, 1);
	//text-shadow: 3px 3px 4px rgba(255, 255, 255, 1);
}
.happy-holi {
	color: #29B6F6;
	text-shadow: 3px 3px 4px rgba(255, 255, 255, 1);
	font-family: 'Pacifico', cursive;
	margin-top: 0em;
	margin-bottom: .6em !important;
	font-size: 3.5em !important;
}
.advance {
	color: #9CCC65;
	color: #4CAF50;
	color: #2E7D32;
	color: #FFA726;
	//text-shadow: 3px 3px 4px rgba(255, 255, 255, 1);
	text-shadow: 3px 3px 4px rgba(0, 0, 0, 1);
}

#getting-started {
	margin: 0.8em  !important;
	font-size: 2em !important;
	color: white;
}

.container {
	background: rgba(255, 255, 255, 0.4);
	padding: 20px 10px;
	margin: 5px;
	width: 98%;
	border-radius: 3px;
	//background-color: red;
}





 .w3_whatsapp_btn {
    border: 1px solid rgba(0, 0, 0, 0.1);
    position: relative;
    letter-spacing: .4px;
    cursor: pointer;
    font-weight: 400;
    text-transform: none;
    color: #fff;
    border-radius: 2px;
    background-color: #5cbe4a;
    background-repeat: no-repeat;
    text-decoration: none;
    text-align: left;
	 -webkit-user-select: none; /* Safari */        
-moz-user-select: none; /* Firefox */
-ms-user-select: none; /* IE10+/Edge */
user-select: none; /* Standard */
}

.w3_whatsapp_btn_large {
    font-size: 14px;
    padding: 7px 10px;
    color: #fff;
}
a.whatsapp { color: #fff; }

input {
	text-shadow: none !important;
}
              
            
!

JS

              
                jQuery( document ).ready(function() {
	var sender = getUrlParameter('name');
	if( !sender == "" ) {
		 $('.name').text(sender.replace("-", " "));
	 } else {
		 $('.name').text("Mstoic");
	 }
	
	jQuery('#getting-started').countdown('2018/03/01', function(event) {
		jQuery(this).html(event.strftime('%w week(s) %d day(s) %H:%M:%S'));
	});
});

$(document).ready(function() {

	var isMobile = {
    Android: function() {
        return navigator.userAgent.match(/Android/i);
    },
    BlackBerry: function() {
        return navigator.userAgent.match(/BlackBerry/i);
    },
    iOS: function() {
        return navigator.userAgent.match(/iPhone|iPad|iPod/i);
    },
    Opera: function() {
        return navigator.userAgent.match(/Opera Mini/i);
    },
    Windows: function() {
        return navigator.userAgent.match(/IEMobile/i);
    },
    any: function() {
        return (isMobile.Android() || isMobile.BlackBerry() || isMobile.iOS() || isMobile.Opera() || isMobile.Windows());
    }
	
};
	
	if( !isMobile.any() ) {
		$(".whatsapp").text("Share");
	}
	
 $(document).on("click", '.whatsapp', function() {
	 var name =  "Mstoic";
	 if( !$(".form_name").val() == "" ) {
		 name = $(".form_name").val();
	 }
	 var url = "https://www.mstoic.com/apps/happy-holi.html" + "?name=";
	 url = url + name.replace(/-/g, ' ');
	 var message = "Wish you a very Happy Holi from " + 
		 name + 
		 " - "
        if( isMobile.any() ) {
			url = encodeURIComponent(url);
			message = message + url;
            var whatsapp_url = "whatsapp://send?text=" + message;
            window.location.href = whatsapp_url;
        } else {
			
			prompt("Copy the text and share: \n", message + url);
        }
    });
});

 $(document).on("click", '.share', function(e) {
	 		window.location.href = "intent:#Intent;action=android.intent.action.SEND;type=text/plain;S.android.intent.extra.TEXT=https%3A%2F%2Fpaul.kinlan.me%2F;S.android.intent.extra.SUBJECT=Amazing;S.browser_fallback_url=https:%3A%2F%2Ftwitter.com%2Fintent%2Ftweet;end";
 });

var getUrlParameter = function getUrlParameter(sParam) {
    var sPageURL = decodeURIComponent(window.location.search.substring(1)),
        sURLVariables = sPageURL.split('&'),
        sParameterName,
        i;

    for (i = 0; i < sURLVariables.length; i++) {
        sParameterName = sURLVariables[i].split('=');

        if (sParameterName[0] === sParam) {
            return sParameterName[1] === undefined ? true : sParameterName[1];
        }
    }
};
              
            
!
999px

Console