How to use a custom font on your website

Custom-Font
For the purpose of this tutorial, I am going to use Pacifico, a font you can find on Font Squirrel.

A custom font is a font that is not of a standard nature (i.e. one that comes with your computer when you buy it), nor is it a Google font, which are readily available for use on the web.

A custom font is something you download from websites like the one mentioned above, purchased from designers or any other method you may use to obtain fonts that are not considered to be web fonts. Typically, people use them on images only.

This tutorial will teach you how to install a custom font on your website in under five minutes and as a result, will open so many more options for you and your web design.

We will utilize font-face feature to add custom fonts.   With font-face feature we can use the fonts which are not installed on the users computer. The font is automatically downloaded when required.

Continue Reading

How to Highlight Particular Dates in JQuery UI Datepicker

Highlighting particular dates

In this post I will cover how to highlight specific dates in Jquery UI Datepicker. It pretty simple actually, we will add a custom CSS class to particular dates and then style those particular dates.

Here are steps which we will be following to highlight particular dates in datepicker:

  1. We use array to hold the dates which will be highlighted.
  2. We will utilize  datepicker beforeShowDay function to add custom CSS classes to the dates in array
  3. We will add CSS rules to style the dates.

Continue Reading

How to Create A Sticky Footer With CSS

Create a fixed footer with CSS

A sticky footer is a great way to encourage people to subscribe to your website’s newsletter, get more eyes on your advertisements or post short and important updates for your visitors.

The difference between a sticky header and a sticky footer is that the footer doesn’t take up “prime real estate” on your blog’s page in the same way that a header does. Visitor’s eyes will naturally make their way down to the footer as they read through your content and it’s not disruptive to their viewing.

What is a sticky footer?

Typically, it’s a bar that runs along the bottom of your webpage, even when scrolling.

Create a fixed footer with CSS

View the live demo here .

The Method

Let’s start out by creating a HTML webpage.

<html>
<head>
<title>My Webpage</title>
<style type="text/css">
</style>
</head>
<body>
Your webpage content goes here. To be able to test the functions of your fixed footer correctly, you need to have enough content so that when viewing you are required to scroll down the page to continue reading.
</body>
</html>

Next, we’ll add the footer div layer to the page.

<html>
<head>
<title>My Webpage</title>
<style type="text/css">
</head>
<body>
Your webpage content goes here. To be able to test the functions of your fixed footer correctly, you need to have enough content so that when viewing you are required to scroll down the page to continue reading.
<div id="footer">
Your fixed footer content goes here. You can use web forms, images, javascript code or whatever you want!
</div>
</body>
</html>

Now that we’ve got the basic set up for your webpage, we will rely on CSS to do the rest of the work. Use the following code in your style.css file or include it in between the script tags I have used above.

I am going to include a little styling for mine, which is optional for you.

body {
background-color: #e4e4e4; /* Styling */
font-family: 'Arial', sans-serif; /* Styling */
font-size: 17px; /* Styling */
}

#footer {
position: fixed;
bottom: 0px;
width: 100%;
overflow: visible;
z-index: 99;
height:40px;
left: 0px;
padding: 5px; /* Styling */
border-top: 2px solid #000000; /* Styling */
background-color: #ffffff; /* Styling */
text-align: center; /* Styling */
}

Not only do you now have a sticky footer on your screen, but it’s also mobile responsive. Keep in mind that you will have to add some additional styling for mobile view if you want the viewer to be able to see what is in the footer. Widths should be set to 100% and heights to auto to ensure it shrinks to size correctly.

Top 10 tools to convert HTML to PDF

PDF (Portable Document Formal) is a useful document format, and as the name portable. Once a document is converted to the PDF format, its formatting remains the same when viewed across a range of devices, irrespective of the platform. Due to its usability, there is often a need to convert documents from various formats to PDF. Webpages, which are basically HTML documents, belong to the same category.

Thus, we present 10 HTML to PDF converters with range of functionalites associated with each one.Continue Reading

Creating animated loaders with CSS3 Animation

spinkit

Introduction

Loaders and Spinners play an important role in the modern dynamic websites. Though they look simple but they play a very important role in simplifying the overall User Experience. There are a lot of ways to create animated loaders, however in this post I will be using the power of CSS3 to create 3 different spinners.

You can view all the working loaders and spinners by clicking “vKIAp” button below. Before we dig in to it, lets find out what CSS3 properties are required to build them.

See the Pen vKIAp by Mohit Bhansali (@mohitbhansali) on CodePen.Continue Reading

Adobe Brackets 1.0, an open source text editor for Web Designers

Multi Cursors

Introduction

Adobe has just launched version 1.0 of Brackets, its free open-source text editor that is built in HTML, CSS and JavaScript, for writing coding in HTML, CSS and JavaScript.

Brackets started as an open-source project over three years ago, and developers who want to customize the text editor to fit their motives can pull the source code from the app’s Github project page and alter it as they wish, and add their changes for others to use.

Currently, Brackets 1.0, as well as a preview of Extract for Brackets (an extension that Adobe itself has been working on) are available for Windows, Mac and Linux. Brackets is targeting mainly at Web developers (front-end) and designers. They are offering interesting features like inline editors (select and press ctrl + E / push command) will show inline window to update particular code without pop-ups or additional tabs, Live Preview to see instantly changes on screen and view CSS selector for quick edits and built in support for preprocessors.

What’s new in Adobe Brackets 1.0?

They are building fresh features and enhancing the existing one for better user experience. Download Brackets, and  explore the excellent stuff.Continue Reading

Create Your Own Mobile Responsive Masonry (Pinterest Style) Content Grid

Traditional Grid - Create Your Own Mobile Responsive Masonry (Pinterest Style) Content Grid

With Pinterest coming out of the woodwork and taking social media by storm in the recent months, it’s apparent that a lot of it’s popularity is down to it’s aesthetically pleasing layout. Pinterest’s “grid view” style for displaying pins is what the design world refers to as a Masonry Grid.

Masonry Grids are different from normal grids in that they do not have to be the same size as each other (like traditional grids created with CSS & HTML) and they slot in perfectly with each other despite their different lengths.

Traditional Grid

Traditional Grid - Create Your Own Mobile Responsive Masonry (Pinterest Style) Content Grid

Masonry Grid

Masonry Grid - Create Your Own Mobile Responsive Masonry (Pinterest Style) Content GridContinue Reading

Less Vs Sass? Who is the winner?

Now a days, you will find many CSS Frameworks available like Less, Sass, Emastic, 960.gs, BluePrint etc. Each stylesheet language is good in the right context, and they have a lot of common features such as:

  • Nesting capabilities
  • Mixins and parametric mixins
  • Namespaces
  • Color functions
  • JavaScript evaluations

Continue Reading

Frontend Development with SASS and Compass: Introduction

SASS

Introduction

SASS (Syntactically Awesome Stylesheets) is a CSS preprocessor which gives you an opportunity to do amazing things with your stylesheets. Interesting huh!?

What is Sass?

The Sass website define Sass as:

Sass is a meta-language on top of CSS that’s used to describe the style of a document cleanly and structurally, with more power than flat CSS allows. Sass both provides a simpler, more elegant syntax for CSS and implements various features that are useful for creating manageable style sheets.(1)

Yes, yes wait ! I know you are gonna ask me “What’s wrong with regular CSS?”. Regular CSS is also correct, there is nothing wrong in it, they are great with all its ability and quality, but they are missing some essential and simple elements. Sass core philosophy is DRY i.e. Don’t Repeat Yourself as it saves time and effort when writing code.Continue Reading

Create Animated Loaders and Spinners with CSS3

circular loader 1

Loaders and spinners are a common sight in webpages, popping up whenever the server loads a page. For long, animated gifs have served the purpose. However, a plethora of custom made, editable CSS spinners are now available. This tutorial will walk you through the creation of basic animated loaders and how to apply elementary mathematics for various transformations, rather than a hit and trial approach.Continue Reading