Monday, 31 March 2014

Hostgator Review - The Good And Bad Points

Hi everyone, this is a quick Hostgator Review. I`ve spoken highly of Hostgator lots of times but never really met a review. So, this is my first review of what I believe is the best web hosting out there. I recommend Hostgator to my friends, family and my clients as well. I also help people create websites, which is part of my business.
Hostgator Review

Hostgator Review – Support

Ever since I started recommend Hostgator I realized a significant drop in requests for help because of Hostgator`s easy to use interface and their awesome 24/7 live chat. Choosing web hosting, the key factor apart from unlimited space/bandwidth is support. You really need someone who is there for you in case that anything goes wrong, and Hostgator`s live support is the best. I`ve personally experienced many online chat services out there and nothing comes even close to Hostgator`s live chat.

Hostgator Review – Pricing

The second best thing I wanted to discuss in my Hostgator review is their pricing. Compared with other hosting providers, Hostgator offers some of the best plans out there. These guys are always on top of the game unlike many other web hosting companies. Their most awesome discount code can give you premium web hosting for as low as $0.01 (if you use the right ones). On top of that, they also have a 45-day money back guarantee. To me, that`s really good if you`re just starting off or are just curious to start a web site and don`t know if you want to continue to give Hostgator a go. So, that`s another plus point.

Hostgator Review – One-Click Installation

The last point I wanted to highlight in my Hostgator Review is the one-click installation script in their cPanel called Fantastico Deluxe. I think that most of professional hosting suppliers have a cPanel included. The only difference is that they do not provide Fantastico Deluxe. So just look up for that and keep in mind that Hostgator has Fantastico Deluxe. The one-click installation enables you to install any type of platform such as WordPress, Joomla, Drupal and much more in just a click! One push of a button and you would have a full website of your choice. Hence, that`s a huge plus.

Hostgator Review – The Bad Points

As I try to make this Hostgator review as honest as possible, let me talk about some bad points of Hostgator. The only complain I have on them is that it can look quite confusing when it comes to the initial registration process. Many of us who are new to web hosting probably don`t know which plan will fit with the needs (hatchling, baby, business plan). That`s why I`ve developed this Hostgator Review and coupon site; to teach you how to sign up with Hostgator, which plans will suit your needs, to show you which are the best codes to use and get the best discounts, etc. . On these pages I`ve pretty much set up everything you need to know in order to obtain your Hostgator account as fast as possible.
That was my Hostgator Review. I hope you enjoyed this little evaluation. For more information on how to apply a coupon or set up your account, just browse our main homepage or click on “Hostgator 1 Cent Hosting” above this hostgator review.

Saturday, 22 March 2014

5 Easy Ways to Improve the SEO of a blog & Boost Traffic

5 easy ways to improve the SEO of a blog

A blogger needs to know at least the basics of SEO. For this, you don't need to be an SEO expert but you need to know the minimum so that your posts are well indexed in the search engines.

The phrase "Content is King" is one of the widest spread Internet memes being used by so many bloggers with the idea that you should focus on having quality content, while the rest isn't that important. This is not true. Quality content is essential, but bloggers shouldn't focus only on this matter. Besides producing quality content, your text needs to be optimized for the search engines.

improve seo, seo tips, boost traffic
Boost traffic & increase SERP visibility with SEO

5 Easy Ways to Improve the SEO of a Blog

Now, let's get to know the basics that any blogger needs to learn about SEO, as well as other simple SEO techniques. Below are 5 easy tips to improve the SEO of your blog:

1. Define the keyword

When you write a post, it is recommended to choose the right SEO keyword for your text. Your purpose is to make this keyword - or term - to be searched on Google, and then get your post among the top. For this, you need to use this keyword a few times in the text.

For example, here the keyword could be SEO, but this term is too common and I could hardly get in the top for this search. Then, I'll work with a phrase or a long tail keyword, so that this post will rank for the term "easy ways to improve the SEO of a blog". I will use this keyword a few times, but without overdoing it.

2. Use the keyword in the post title

Now that I have defined the keyword, I will use it in the post title. This step is very important, and certainly will help you to get a better SEO rank. For instance, the post title contains the easy ways to improve the SEO of a blog keyword, along with other words to form an attractive and optimized title for SEO.

3. Use the keyword in H2 tags

You must also use heading tags (h2, h3) in your posts. Here, we added the "easy ways to improve the SEO of a blog" keyword in a H2 heading. Do this always as it will help you rank well in the search results. If you don't know or don't understand what are the heading tags, I would suggest to do a further research on this topic.


4. Use the keyword in the text

Include the chosen keywords throughout the text. Especially in the first paragraph (please note that I have repeated the title in italics in the first sentence). But be careful when doing this, there is a maximum and minimum limit for that. A good keyword density is between 1.5% to 4.5% for best results. Less than that will have no effect and more can alert the search engines and your text might be considered spam.

5. Publish Posts with 300 words or more

Posts under 300 words have little chance to be among the top results in search engines. Of course, you will be able to rank for multiple keywords that are less popular with less than 300 words, but for the most competitive keywords that have the potential to bring a greater number of visits, it will be nearly impossible.

Thus, it is recommended to write posts with more than 300 words. It's not hard when you really understand the topic you're talking about.

Conclusion

As you can see, with some simple SEO techniques you can improve the traffic coming to your blog from the search engines. I hope you enjoyed these 5 easy ways to improve the SEO of a blog!

What is the difference between padding and margins?

For those who would like to know more about HTML and CSS, in this post we will learn the differences between margin and padding CSS properties that are used to add space between the HTML elements, thus preventing the elements from getting 'stuck' together.

Although both have similar functions, each work in a different way.
  1. Padding determines the inner margins, being used for changing the distance between the content of a given element and its border.
  2. Margin is the space outside of an element affecting how far the element is away from other elements.
For a better understanding of how the padding and margin work, take a look at the picture below:

padding and margin, css proprieties
Difference between margin and padding

Just as you have the option to define the borders for each side of your HTML elements (eg. borders for the sidebar), you can do the same with the margin and padding properties. All you need to to do is to change the top, right, bottom and left values​​.

The values that you can use include: pixels (px), centimeters (cm), millimeters (mm). em units (em), x-height (ex), inches (in), picas (pc) and point sizes (pt).

When using margin and padding, you need to add a value for each 4 corners of an element, as follows: top, right, bottom, left. Each value must refer to the each side of the HTML element. The first value is for the top, and they follow a clockwise direction, so the value would be close to the right, then bottom, and finally, left.

Example 1:
padding:5px 15px 5px 15px;
  • top padding is of 5px 
  • right padding is of 15px 
  • bottom padding is of 5px 
  • left padding is of 15px
margin: 10px 5px 10px 5px;
  • top margin is of 10px
  • right margin is of 5px
  • bottom margin is of 10px
  • left margin is of 5px
If you define a single value (instead of 4), the distance applies on the all sides, i.e. it will be applied on the 4 sides of the HTML element that you want to modify.

Example 2:
padding: 5px (top and bottom) 15px (left and right);
margin: 10px (top and bottom) 5px (left and right);

If it helps you visually, think of an A4 page of type inside a picture frame. The margin is the space between the edge of the sheet of paper and the other elements (the parts of the frame), while the padding would be the space between the edge of the sheet and where the type starts on the page. The border would be the edge of the sheet of paper.

It's probably easier to understand if you have borders, then it also becomes obvious which one to use. Do you want "space" after the border (outside the element = margin) or before the border (inside the element = padding).

Thursday, 13 March 2014

Hostgator vs Bluehost Review – Which Web Hosting Provider is Better?

Bluehost Discount Makes them Cheaper

Although Bluehost coupon codes can be hard to find, we’ve managed to hook up a special discount link for you should you decide on them after this “Hostgator vs Bluehost review“. The standard Bluehost package is usually charged at $6.95 per month, but you can get it at $5.95 per month through this link: Bluehost Discount.
Hostgator vs Bluehost Review – Which Web Hosting Provider is Better?

Compared to a similar package on Hostgator with a Hostgator Coupon Code 2014, Bluehost is literally $0.01 cheaper through our site. Although there’s still the question of which web host is better, Bluehost or Hostgator? This is a tough question since both web hosting providers are similar in many ways.
Both Bluehost and Hostgator have the following:
  • Unlimited Domains (except for Hostgator’s “Hatchling” package)
  • Unlimited Disk Space
  • Unlimited Bandwidth
  • Free Site Builders
  • Free Website Templates
  • cPanel Platform
  • Top class 24/7 Customer Support
  • etc.
Is Bluehost better than Hostgator?
It’s really hard to say to be honest. Both Hostgator and Bluehost are top quality web hosting providers in nearly every aspect, so let’s see if we can break things down a bit in this Bluehost Review and mention the most important factors.
  • Customer Support: These are the 2 web hosts which both have great customer service, although I’d say from my experience that Hostgator has a slight edge over Bluehost when it comes to customer satisfaction. Bluehost support requires you to be a bit more knowledgeable, where Hostgator support is a bit more newbie-friendly and will go the extra mile.
  • Pricing: The pricing is very similar for shared hosting, but looking at Bluehost’s “Pro” package which is basically VPS hosting, -priced at $19.95 through our page, Hostgator beats them with a low $15.96 per month.
  • Website Loading Speed: Another very close call. After comparing 2 very similar sites on each hosting account, Bluehost servers have an average page loading time of 1-3 seconds, whereas Hostgator is between 2-3 seconds. Points for Bluehost here.
  • Website Downtime: With Bluehost we’ve had 2 very short downtimes over the past year which is not bad at all. However, we’ve only had a 20-30 minute downtime over the past year with Hostgator, so they win by a fraction.
  • Bonus Advertising Credits: Bluehost gives you $75 Google Adwords Credit and Hostgator gives $100 credit (U.S. Only). Hostgator wins by $25.
  • Packages: Bluehost only has 2 packages to choose from, standard and Pro, whereas Hostgator’s got your every web hosting need covered with a wide range of packages to choose from.
The final score? Bluehost 1, Hostgator 5. Despite the scoreline, it was still a rather close call.

Bluehost Review – Conclusion

Regardless of all comparisons, Bluehost is a fantastic web host and the reviews speak for themselves. You can’t go wrong with these guys. Bluehost is by far our second favorite web hosting provider out of the lot. Lightning fast loading speed and excellent customer support, you simply can’t go wrong with Bluehost!
Advantages:
  • Excellent Customer Support
  • cPanel Platform
  • Lightning Page Load Times
  • Cloud Servers
  • Tons of Free Tools
Disadvantages:
  • Well, none.

Tuesday, 11 March 2014

WordPress vs Joomla vs Drupal

If you are thinking about using a content management system then you’re more than likely will be selecting from the three most popular: WordPress, Joomla, and Drupal.  Now the tough question for web-masters is which of these management systems in the best.  To help you make the best choice for your website we will take a quick look at what each has to offer in comparison to the others.

WordPress CMS

WordPress came onto the internet scene in 2003.  This content management system is best know as a blogging platform, mainly due to the WordPress.com service.  What gives WordPress its advantage is the simplicity to power a blog, but at the same time it can handle even more complex tasks.  This makes it the best option for websites that are starting with a limited plan but are in hopes of expanding their website into something larger.
Upside of WordPress
  • Most Prevalent CMS
  • Easiest Content Creator
  • Easiest to Instal
  • Easiest Learning Curve
  • Balance between Joomla and Drupal
  • Best For Blogging
Downside of WordPress
  • Very Plan By Default
  • Hidden Controls
  • Content is Location-Based
WordPress Summed Up
This unique content management system is the most recognizable blogging platform.  The system itself may not be as sophisticated or versatile as Drupal or Joomla, but when it comes to speed and simplicity, WordPress wins easily.  Even the least experienced web-masters can create their new website in a matter of minutes.  Installation of WordPress is literally as simple as a single click when you select a web hosting provider such as HostGator.  The one negative that comes from using WordPress is that some of the best features are hard to find from the dashboard.
Nothing comes close to the ease of creating content using WordPress, and the same can be said for selecting a theme or template to give your website that professional looks.  WordPress even offers additional add-ons, better known as plugins, that can be installed with a single click.  This unique platform can even handle e-commerce websites, as it handles large inventories.  However, it’s best the perfect solution for the smaller sites that are selling a few items.

Joomla CMS

Fairly new to the content management world, Joomla arrived in 2005 as a Mambo CMS fork.  This CMS platform is centralized around giving developers the power to build template-based websites.  Unlike WordPress and Drupal, Joomla what is known as a model-view-controller structure, making it an excellent asset for developers looking to stretch the platforms legs.  The default installation of Joomla offers many features and extensions are only available as add-ons for WordPress and Drupal.
Upside of Joomla
  • Second Most Prevalent CMS
  • Build-In SEO Friendly URLs
  • Intuitive Control Panel
  • Easiest E-commerce Platform
  • Most Sophisticated Platform
  • Explicit Installation Process
Downside of Joomla
  • Some Coding Required For Configuration
  • Controls Requires Tedious Tasks
  • Sometimes Unstable and Crashes Occasionally
  • Sample Data Can Sometimes Be A Pain
Joomla Summed Up
Joomla uses a small step approach and everything is documented in a very usable form.  The controls are very intuitive, however, simplicity is sometimes a limitation as the platform requires users to perform menial tasks repeatedly.  As content management systems are suppose to be code free, Joomla doesn’t deliver, as is almost always requires users to play around with the coding.  Lastly, adding extensions and plug-ins is much more difficult as compared to its competitors in WordPress and Drupal.

Drupal CMS

This open source solution was released in 2001 by Dries Buytaert.  Drupal is very similar to Joomla in that their primary goals are to achieve powerful template-based websites, all while remaining user friendly.  The Drupal CMS provides a excellent alternative to the blog-oriented WordPress system.  It is also very popular for knowledge management and business collaboration websites and is well known for for being the tech that runs the whitehouse.gov website.
Upside of Drupal
  • Very Easy Configuration
  • Very Powerful Admin Controls
  • Dashboard Supports Advanced Customization
  • Offers Simple Static Pages
  • Easy Add-on Installation
  • Excellent E-commerce Platform
Downside of Drupal
  • Complicated Installation Process
  • Very Tough Learning Curve
  • No Rich Text Editor By Default
  • No Built-In Social Media Tools
  • Control Flexibility Causes Some Complexity
Drupal Summed Up
The installation of Drupal is very good and similar to that of Joomla.  The Drupal controls are more complicated than Joomla’s, however, they’re much more customizable and powerful.  installing add-ons to Drupal is more similar to WordPress in the sense that it’s much more user friendly as compared to Joomla.  Drupal is second in popularity only to WordPress, but at the same time the commercial community is far less than Joomla.

Similarities Between The “Big 3″

WordPress, Joomla, and Drupal are very similar in many different aspects.  Each of these content management systems use MySQL as the back-end database and are all written in PHP form.  They also all have a great collection of add-ons and commercial support to go along with their default features.  Lastly, they are all offered for free by web hosts and can be installed with single click installations.  This easy instal option keeps the burden of building a website minimal.

Conclusion

Each of these content management systems is an excellent option, which tells the tale of why their the most well known.  Joomla is the most modern option, which as allowed for it to learned from WordPress and Drupal’s mistakes.  It also may be the number one option for someone with strong technical skills.  On the flip side of things, WordPress is most certainly the number one option for those without technical skills.  Out of the “Big 3,” Drupal has superb potential, but will require strong technical skills similar to Joomla.

Sunday, 9 March 2014

Add a Custom jQuery Lightbox To Blogger

If you are not satisfied with the default Lightbox set up by Blogger, here's another cool way to show off your pictures. In case you missed it, I have already shown in one of my posts how to customize the Blogger Lightbox by changing the background color, borders or the text color. This tutorial will show you how to replace it entirely with a cool jQuery Lightbox plugin that is very popular among bloggers.

What this Lightbox does is to display a larger versions of the images that will pop-up into a larger box once we click on them, and allows us to easily navigate through that set of photos by using the previous and next buttons.

jquery lightbox, blogger plugins
To see how it works, visit the demo blog and click on any picture to enlarge it.


Adding jQuery Lightbox to Blogger

Step 1. From your Blogger Dashboard, click on "Template" > "Edit HTML".

blogger edit html

Step 2. Click anywhere on the code area and press the CTRL + F keys to open the search box, then paste the following tag inside the search box and hit Enter to find it:
]]></b:skin>
Step 3. Choose one of the Lighbox styles from below and paste the CSS code just above the ]]></b:skin> tag:

Custom Blogger Lightbox with Light Background

jquery lightbox white
#jquery-overlay{position:absolute;top:0;left:0;z-index:90;width:100%;height:500px;}
#jquery-lightbox{position:absolute;top:10%;left:0;width:100%;z-index:100;text-align:center;line-height:0;}
#jquery-lightbox a,#jquery-lightbox a:hover{border:none;}
#jquery-lightbox a img{border:none;}
#lightbox-container-image-box{position:relative;background-color:#fff;max-width: 960px;max-height: 560px;margin:0 auto;}
#lightbox-container-image{padding:10px;}
img#lightbox-image {max-height: 540px;max-width: 940px;}
#lightbox-loading{position:absolute;top:40%;left:0%;height:25%;width:100%;text-align:center;line-height:0;}
#lightbox-nav{position:absolute;top:0;left:0;height:100%;width: 100%;z-index:10;}
#lightbox-container-image-box > #lightbox-nav{left:0;}
#lightbox-nav a{outline:none;}
#lightbox-nav-btnPrev,#lightbox-nav-btnNext{width:49%;height:100%;zoom:1;display:block;}
#lightbox-nav-btnPrev{left:10%;float:left;}
#lightbox-nav-btnNext{right:10%;float:right;}
#lightbox-container-image-data-box{font:10px Verdana,Helvetica,sans-serif;background-color:#fff;margin:0 auto;line-height:1.4em;overflow:auto;max-width: 940px;;padding:0 10px 0;}
#lightbox-container-image-data{padding:0 10px;color:#555;}
#lightbox-container-image-data #lightbox-image-details{width:70%;float:left;text-align:left;}
#lightbox-image-details-caption{font-weight:bold;}
#lightbox-image-details-currentNumber{display:block;clear:left;padding-bottom:1.0em;}
#lightbox-secNav-btnClose{width:66px;float:right;padding-bottom:0.7em;}

Custom Blogger Lightbox with Dark Background:

jquery lightbox dark
#jquery-overlay{position:absolute;top:0;left:0;z-index:90;width:100%;height:500px;}
#jquery-lightbox{position:absolute;top:10%;left:0;width:100%;z-index:100;text-align:center;line-height:0}
#jquery-lightbox a,#jquery-lightbox a:hover{border:none}
#jquery-lightbox a img{border:none;}
#lightbox-container-image-box{position:relative;background-color:#000;max-width: 960px;max-height: 560px;margin:0 auto}
#lightbox-container-image{padding:10px;}
img#lightbox-image {max-height: 540px;max-width: 940px;}
#lightbox-loading{position:absolute;top:40%;left:0%;height:25%;width:100%;text-align:center;line-height:0}
#lightbox-nav{position:absolute;top:0;left:0;height:100%;width: 100%;z-index:10}
#lightbox-container-image-box > #lightbox-nav{left:0;}
#lightbox-nav a{outline:none}
#lightbox-nav-btnPrev,#lightbox-nav-btnNext{width:49%;height:100%;zoom:1;display:block}
#lightbox-nav-btnPrev{left:10%;float:left}
#lightbox-nav-btnNext{right:10%;float:right}
#lightbox-container-image-data-box{font:10px Verdana,Helvetica,sans-serif;background-color:#000;margin:0 auto;line-height:1.4em;overflow:auto;max-width: 940px;;padding:0 10px 0}
#lightbox-container-image-data{padding:0 10px;color:#fff}
#lightbox-container-image-data #lightbox-image-details{width:70%;float:left;text-align:left}
#lightbox-image-details-caption{font-weight:bold}
#lightbox-image-details-currentNumber{display:block;clear:left;padding-bottom:1.0em}
#lightbox-secNav-btnClose{width:66px;float:right;padding-bottom:0.7em}

Step 4. Now find the following tag and just above it, add one of the scripts below:
</head>

Script for Lightbox with Light Background:

<script src='http://ajax.googleapis.com/ajax/libs/jquery/1/jquery.min.js' type='text/javascript'/>
<script type='text/javascript'>
//<![CDATA[
(function(a){a.fn.lightBox=function(p){p=jQuery.extend({overlayBgColor:"#000",overlayOpacity:0.9,fixedNavigation:false,imageLoading:"https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjC0DvtjioQI7_94OMEE4Duym3Kqe9XCC4Rkvgl2ujMKRNBbvPCf9Nq3cOZGiIwe8yIRexET6nLjhUl-it4oopUmkKbr38nngGLus3VKMD1d8XS138A7itjAfAx5OgyxP0q22RMtOrGY4s/s1600/loading.gif",imageBtnPrev:"https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhDvBxFbQiiKyLkahbozc4mzur89MxFVe6rVGzsn2kylMOXbCdeHjG54HPhjzVJ4tQdZpptri_DSgEk3hlynZ7wy69jR4RzYQdiHHQ3KcsQrakc5kTsTUIZXP5opuO8qj0kBc4uH1kERjQ/s1600/prev-image.gif",imageBtnNext:"https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiKnYQh-9X9k-nFm_MIhChlYWvDwcSBK1_2qWnNG1bM7KsQPu9JjGr-UddBwwgC2bqTzhHJ_1NToKqGEC5yI-5o2YbsQTmGBGzrZ9X6DZZHM0ugd81juTxEK8rqxzdL4RjqJhqM4WJmhwA/s1600/next-image.gif",imageBtnClose:"https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgsuUgIk1EzrYTnq38utSPIw7zOjZkbrSfy2FJ8kH4GfG6CmJxWyHgvkqOFIKyiQRFTehu7k6aCRTkbo-TFH_VIU1dT-DO25jjDLUztpYNwGCX6w6quT2NlU3a8tylthNJf-tLLYmUe2I4/s1600/close-image.gif",imageBlank:"https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEheHnfadarVzxnr-3FvbI3iwdxUqg-iINbBS7PNoQsQNQ5OPVbJ2Y1FNWpGaPIjnbLYuhyphenhyphenTkyWJgdxhoKUC0vqxM3942NrVUbZR9FHgBGuOz7LPWJMmGYr4QWQa6mxSWmwTiAN-wg4VVN0/s1600/blank.gif",containerBorderSize:10,containerResizeSpeed:400,txtImage:"Image",txtOf:"of",keyToClose:"c",keyToPrev:"p",keyToNext:"n",imageArray:[],activeImage:0},p);var i=this;function r(){o(this,i);return false}function o(v,u){a("embed, object, select").css({visibility:"hidden"});c();p.imageArray.length=0;p.activeImage=0;if(u.length==1){p.imageArray.push(new Array(v.getAttribute("href"),v.getAttribute("title")))}else{for(var t=0;t<u.length;t++){p.imageArray.push(new Array(u[t].getAttribute("href"),u[t].getAttribute("title")))}}while(p.imageArray[p.activeImage][0]!=v.getAttribute("href")){p.activeImage++}l()}function c(){a("body").append('<div id="jquery-overlay"></div><div id="jquery-lightbox"><div id="lightbox-container-image-box"><div id="lightbox-container-image"><img id="lightbox-image"><div style="" id="lightbox-nav"><a href="#" id="lightbox-nav-btnPrev"></a><a href="#" id="lightbox-nav-btnNext"></a></div><div id="lightbox-loading"><a href="#" id="lightbox-loading-link"><img src="'+p.imageLoading+'"></a></div></div></div><div id="lightbox-container-image-data-box"><div id="lightbox-container-image-data"><div id="lightbox-image-details"><span id="lightbox-image-details-caption"></span><span id="lightbox-image-details-currentNumber"></span></div><div id="lightbox-secNav"><a href="#" id="lightbox-secNav-btnClose"><img src="'+p.imageBtnClose+'"></a></div></div></div></div>');var t=f();a("#jquery-overlay").css({backgroundColor:p.overlayBgColor,opacity:p.overlayOpacity,width:t[0],height:t[1]}).fadeIn();var u=h();a("#jquery-lightbox").css({top:u[1]+(t[3]/10),left:u[0]}).show();a("#jquery-overlay,#jquery-lightbox").click(function(){b()});a("#lightbox-loading-link,#lightbox-secNav-btnClose").click(function(){b();return false});a(window).resize(function(){var v=f();a("#jquery-overlay").css({width:v[0],height:v[1]});var w=h();a("#jquery-lightbox").css({top:w[1]+(v[3]/10),left:w[0]})})}function l(){a("#lightbox-loading").show();if(p.fixedNavigation){a("#lightbox-image,#lightbox-container-image-data-box,#lightbox-image-details-currentNumber").hide()}else{a("#lightbox-image,#lightbox-nav,#lightbox-nav-btnPrev,#lightbox-nav-btnNext,#lightbox-container-image-data-box,#lightbox-image-details-currentNumber").hide()}var t=new Image();t.onload=function(){a("#lightbox-image").attr("src",p.imageArray[p.activeImage][0]);j(t.width,t.height);t.onload=function(){}};t.src=p.imageArray[p.activeImage][0]}function j(w,z){var t=a("#lightbox-container-image-box").width();var y=a("#lightbox-container-image-box").height();var x=(w+(p.containerBorderSize*2));var v=(z+(p.containerBorderSize*2));var u=t-x;var A=y-v;a("#lightbox-container-image-box").animate({width:x,height:v},p.containerResizeSpeed,function(){g()});if((u==0)&&(A==0)){if(a.browser.msie){n(250)}else{n(100)}}a("#lightbox-container-image-data-box").css({width:w});a("#lightbox-nav-btnPrev,#lightbox-nav-btnNext").css({height:z+(p.containerBorderSize*2)})}function g(){a("#lightbox-loading").hide();a("#lightbox-image").fadeIn(function(){k();s()});q()}function k(){a("#lightbox-container-image-data-box").slideDown("fast");a("#lightbox-image-details-caption").hide();if(p.imageArray[p.activeImage][1]){a("#lightbox-image-details-caption").html(p.imageArray[p.activeImage][1]).show()}if(p.imageArray.length>1){a("#lightbox-image-details-currentNumber").html(p.txtImage+" "+(p.activeImage+1)+" "+p.txtOf+" "+p.imageArray.length).show()}}function s(){a("#lightbox-nav").show();a("#lightbox-nav-btnPrev,#lightbox-nav-btnNext").css({background:"transparent url("+p.imageBlank+") no-repeat"});if(p.activeImage!=0){if(p.fixedNavigation){a("#lightbox-nav-btnPrev").css({background:"url("+p.imageBtnPrev+") left 15% no-repeat"}).unbind().bind("click",function(){p.activeImage=p.activeImage-1;l();return false})}else{a("#lightbox-nav-btnPrev").unbind().hover(function(){a(this).css({background:"url("+p.imageBtnPrev+") left 15% no-repeat"})},function(){a(this).css({background:"transparent url("+p.imageBlank+") no-repeat"})}).show().bind("click",function(){p.activeImage=p.activeImage-1;l();return false})}}if(p.activeImage!=(p.imageArray.length-1)){if(p.fixedNavigation){a("#lightbox-nav-btnNext").css({background:"url("+p.imageBtnNext+") right 15% no-repeat"}).unbind().bind("click",function(){p.activeImage=p.activeImage+1;l();return false})}else{a("#lightbox-nav-btnNext").unbind().hover(function(){a(this).css({background:"url("+p.imageBtnNext+") right 15% no-repeat"})},function(){a(this).css({background:"transparent url("+p.imageBlank+") no-repeat"})}).show().bind("click",function(){p.activeImage=p.activeImage+1;l();return false})}}m()}function m(){a(document).keydown(function(t){d(t)})}function e(){a(document).unbind()}function d(t){if(t==null){keycode=event.keyCode;escapeKey=27}else{keycode=t.keyCode;escapeKey=t.DOM_VK_ESCAPE}key=String.fromCharCode(keycode).toLowerCase();if((key==p.keyToClose)||(key=="x")||(keycode==escapeKey)){b()}if((key==p.keyToPrev)||(keycode==37)){if(p.activeImage!=0){p.activeImage=p.activeImage-1;l();e()}}if((key==p.keyToNext)||(keycode==39)){if(p.activeImage!=(p.imageArray.length-1)){p.activeImage=p.activeImage+1;l();e()}}}function q(){if((p.imageArray.length-1)>p.activeImage){objNext=new Image();objNext.src=p.imageArray[p.activeImage+1][0]}if(p.activeImage>0){objPrev=new Image();objPrev.src=p.imageArray[p.activeImage-1][0]}}function b(){a("#jquery-lightbox").remove();a("#jquery-overlay").fadeOut(function(){a("#jquery-overlay").remove()});a("embed, object, select").css({visibility:"visible"})}function f(){var v,t;if(window.innerHeight&&window.scrollMaxY){v=window.innerWidth+window.scrollMaxX;t=window.innerHeight+window.scrollMaxY}else{if(document.body.scrollHeight>document.body.offsetHeight){v=document.body.scrollWidth;t=document.body.scrollHeight}else{v=document.body.offsetWidth;t=document.body.offsetHeight}}var u,w;if(self.innerHeight){if(document.documentElement.clientWidth){u=document.documentElement.clientWidth}else{u=self.innerWidth}w=self.innerHeight}else{if(document.documentElement&&document.documentElement.clientHeight){u=document.documentElement.clientWidth;w=document.documentElement.clientHeight}else{if(document.body){u=document.body.clientWidth;w=document.body.clientHeight}}}if(t<w){pageHeight=w}else{pageHeight=t}if(v<u){pageWidth=v}else{pageWidth=u}arrayPageSize=new Array(pageWidth,pageHeight,u,w);return arrayPageSize}function h(){var u,t;if(self.pageYOffset){t=self.pageYOffset;u=self.pageXOffset}else{if(document.documentElement&&document.documentElement.scrollTop){t=document.documentElement.scrollTop;u=document.documentElement.scrollLeft}else{if(document.body){t=document.body.scrollTop;u=document.body.scrollLeft}}}arrayPageScroll=new Array(u,t);return arrayPageScroll}function n(v){var u=new Date();t=null;do{var t=new Date()}while(t-u<v)}return this.unbind("click").click(r)}})(jQuery);$(document).ready(function(){$('a[href$=jpg]:has(img)').lightBox();$('a[href$=jpeg]:has(img)').lightBox();$('a[href$=png]:has(img)').lightBox();$('a[href$=gif]:has(img)').lightBox();$('a[href$=bmp]:has(img)').lightBox();});
//]]>
</script>

Script for Lightbox with Dark Background:

<script src='http://ajax.googleapis.com/ajax/libs/jquery/1/jquery.min.js' type='text/javascript'/>
<script type='text/javascript'>
//<![CDATA[
(function(a){a.fn.lightBox=function(p){p=jQuery.extend({overlayBgColor:"#000",overlayOpacity:0.9,fixedNavigation:false,imageLoading:"https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgPOtbjZoNRQE_d5hyZq53buhmz2Yz9UDdrkYfT_tkQDR9EVfzjpQbrW8-SBTmpuhMLLJu7HnuW1yR2Gr13aisA3yuV4WrALVt13hn0DyCAR4RTCo-aqZxn53XUAzmpwt947O9Cjgq7pD8/s1600/loading-black.gif",imageBtnPrev:"https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjB0W6YM-qmFhyphenhyphenAMiXggqbOjSz7hDBMQ3B031dQ5E-gjDP7CVd9uvfm5Bd13PtqEWLlmshHXGajaZleus6TTiaLKwMXdbiXYCpJ356diITxQ3QRIFIWZDaphmfQd4Estdr4ANNaupJL0mk/s1600/prev-image-black.gif",imageBtnNext:"https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhhxjPiT0FR4lQf8BYUmtFMUEVRdB273noIBap4PgK4sqOMcWCLBzSeHGzFCp2o1HBu9f6heDzFN8xtuqhJ_KjAq9SlWh-pA2WpLIQ60A2gzTL153KHevmPylUPTLsWWDlbQN-2jqCyGeQ/s1600/next-image-black.gif",imageBtnClose:"https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjoFjTvhMy0ioP0-_pGncTAC9NBgQtsjSaoWWSW_rwQ8ZHJ9kzSO6PjgSDX8sT0lQY0DaGLWu5VnAwoCcvulp5Ol24bP9PlqccCuUPnxT83zmhrucyA99fYNWDd_Ily1pAqdFg9j3YcaUA/s1600/close-image-black.gif",imageBlank:"https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEheHnfadarVzxnr-3FvbI3iwdxUqg-iINbBS7PNoQsQNQ5OPVbJ2Y1FNWpGaPIjnbLYuhyphenhyphenTkyWJgdxhoKUC0vqxM3942NrVUbZR9FHgBGuOz7LPWJMmGYr4QWQa6mxSWmwTiAN-wg4VVN0/s1600/blank.gif",containerBorderSize:10,containerResizeSpeed:400,txtImage:"Image",txtOf:"of",keyToClose:"c",keyToPrev:"p",keyToNext:"n",imageArray:[],activeImage:0},p);var i=this;function r(){o(this,i);return false}function o(v,u){a("embed, object, select").css({visibility:"hidden"});c();p.imageArray.length=0;p.activeImage=0;if(u.length==1){p.imageArray.push(new Array(v.getAttribute("href"),v.getAttribute("title")))}else{for(var t=0;t<u.length;t++){p.imageArray.push(new Array(u[t].getAttribute("href"),u[t].getAttribute("title")))}}while(p.imageArray[p.activeImage][0]!=v.getAttribute("href")){p.activeImage++}l()}function c(){a("body").append('<div id="jquery-overlay"></div><div id="jquery-lightbox"><div id="lightbox-container-image-box"><div id="lightbox-container-image"><img id="lightbox-image"><div style="" id="lightbox-nav"><a href="#" id="lightbox-nav-btnPrev"></a><a href="#" id="lightbox-nav-btnNext"></a></div><div id="lightbox-loading"><a href="#" id="lightbox-loading-link"><img src="'+p.imageLoading+'"></a></div></div></div><div id="lightbox-container-image-data-box"><div id="lightbox-container-image-data"><div id="lightbox-image-details"><span id="lightbox-image-details-caption"></span><span id="lightbox-image-details-currentNumber"></span></div><div id="lightbox-secNav"><a href="#" id="lightbox-secNav-btnClose"><img src="'+p.imageBtnClose+'"></a></div></div></div></div>');var t=f();a("#jquery-overlay").css({backgroundColor:p.overlayBgColor,opacity:p.overlayOpacity,width:t[0],height:t[1]}).fadeIn();var u=h();a("#jquery-lightbox").css({top:u[1]+(t[3]/10),left:u[0]}).show();a("#jquery-overlay,#jquery-lightbox").click(function(){b()});a("#lightbox-loading-link,#lightbox-secNav-btnClose").click(function(){b();return false});a(window).resize(function(){var v=f();a("#jquery-overlay").css({width:v[0],height:v[1]});var w=h();a("#jquery-lightbox").css({top:w[1]+(v[3]/10),left:w[0]})})}function l(){a("#lightbox-loading").show();if(p.fixedNavigation){a("#lightbox-image,#lightbox-container-image-data-box,#lightbox-image-details-currentNumber").hide()}else{a("#lightbox-image,#lightbox-nav,#lightbox-nav-btnPrev,#lightbox-nav-btnNext,#lightbox-container-image-data-box,#lightbox-image-details-currentNumber").hide()}var t=new Image();t.onload=function(){a("#lightbox-image").attr("src",p.imageArray[p.activeImage][0]);j(t.width,t.height);t.onload=function(){}};t.src=p.imageArray[p.activeImage][0]}function j(w,z){var t=a("#lightbox-container-image-box").width();var y=a("#lightbox-container-image-box").height();var x=(w+(p.containerBorderSize*2));var v=(z+(p.containerBorderSize*2));var u=t-x;var A=y-v;a("#lightbox-container-image-box").animate({width:x,height:v},p.containerResizeSpeed,function(){g()});if((u==0)&&(A==0)){if(a.browser.msie){n(250)}else{n(100)}}a("#lightbox-container-image-data-box").css({width:w});a("#lightbox-nav-btnPrev,#lightbox-nav-btnNext").css({height:z+(p.containerBorderSize*2)})}function g(){a("#lightbox-loading").hide();a("#lightbox-image").fadeIn(function(){k();s()});q()}function k(){a("#lightbox-container-image-data-box").slideDown("fast");a("#lightbox-image-details-caption").hide();if(p.imageArray[p.activeImage][1]){a("#lightbox-image-details-caption").html(p.imageArray[p.activeImage][1]).show()}if(p.imageArray.length>1){a("#lightbox-image-details-currentNumber").html(p.txtImage+" "+(p.activeImage+1)+" "+p.txtOf+" "+p.imageArray.length).show()}}function s(){a("#lightbox-nav").show();a("#lightbox-nav-btnPrev,#lightbox-nav-btnNext").css({background:"transparent url("+p.imageBlank+") no-repeat"});if(p.activeImage!=0){if(p.fixedNavigation){a("#lightbox-nav-btnPrev").css({background:"url("+p.imageBtnPrev+") left 15% no-repeat"}).unbind().bind("click",function(){p.activeImage=p.activeImage-1;l();return false})}else{a("#lightbox-nav-btnPrev").unbind().hover(function(){a(this).css({background:"url("+p.imageBtnPrev+") left 15% no-repeat"})},function(){a(this).css({background:"transparent url("+p.imageBlank+") no-repeat"})}).show().bind("click",function(){p.activeImage=p.activeImage-1;l();return false})}}if(p.activeImage!=(p.imageArray.length-1)){if(p.fixedNavigation){a("#lightbox-nav-btnNext").css({background:"url("+p.imageBtnNext+") right 15% no-repeat"}).unbind().bind("click",function(){p.activeImage=p.activeImage+1;l();return false})}else{a("#lightbox-nav-btnNext").unbind().hover(function(){a(this).css({background:"url("+p.imageBtnNext+") right 15% no-repeat"})},function(){a(this).css({background:"transparent url("+p.imageBlank+") no-repeat"})}).show().bind("click",function(){p.activeImage=p.activeImage+1;l();return false})}}m()}function m(){a(document).keydown(function(t){d(t)})}function e(){a(document).unbind()}function d(t){if(t==null){keycode=event.keyCode;escapeKey=27}else{keycode=t.keyCode;escapeKey=t.DOM_VK_ESCAPE}key=String.fromCharCode(keycode).toLowerCase();if((key==p.keyToClose)||(key=="x")||(keycode==escapeKey)){b()}if((key==p.keyToPrev)||(keycode==37)){if(p.activeImage!=0){p.activeImage=p.activeImage-1;l();e()}}if((key==p.keyToNext)||(keycode==39)){if(p.activeImage!=(p.imageArray.length-1)){p.activeImage=p.activeImage+1;l();e()}}}function q(){if((p.imageArray.length-1)>p.activeImage){objNext=new Image();objNext.src=p.imageArray[p.activeImage+1][0]}if(p.activeImage>0){objPrev=new Image();objPrev.src=p.imageArray[p.activeImage-1][0]}}function b(){a("#jquery-lightbox").remove();a("#jquery-overlay").fadeOut(function(){a("#jquery-overlay").remove()});a("embed, object, select").css({visibility:"visible"})}function f(){var v,t;if(window.innerHeight&&window.scrollMaxY){v=window.innerWidth+window.scrollMaxX;t=window.innerHeight+window.scrollMaxY}else{if(document.body.scrollHeight>document.body.offsetHeight){v=document.body.scrollWidth;t=document.body.scrollHeight}else{v=document.body.offsetWidth;t=document.body.offsetHeight}}var u,w;if(self.innerHeight){if(document.documentElement.clientWidth){u=document.documentElement.clientWidth}else{u=self.innerWidth}w=self.innerHeight}else{if(document.documentElement&&document.documentElement.clientHeight){u=document.documentElement.clientWidth;w=document.documentElement.clientHeight}else{if(document.body){u=document.body.clientWidth;w=document.body.clientHeight}}}if(t<w){pageHeight=w}else{pageHeight=t}if(v<u){pageWidth=v}else{pageWidth=u}arrayPageSize=new Array(pageWidth,pageHeight,u,w);return arrayPageSize}function h(){var u,t;if(self.pageYOffset){t=self.pageYOffset;u=self.pageXOffset}else{if(document.documentElement&&document.documentElement.scrollTop){t=document.documentElement.scrollTop;u=document.documentElement.scrollLeft}else{if(document.body){t=document.body.scrollTop;u=document.body.scrollLeft}}}arrayPageScroll=new Array(u,t);return arrayPageScroll}function n(v){var u=new Date();t=null;do{var t=new Date()}while(t-u<v)}return this.unbind("click").click(r)}})(jQuery);$(document).ready(function(){$('a[href$=jpg]:has(img)').lightBox();$('a[href$=jpeg]:has(img)').lightBox();$('a[href$=png]:has(img)').lightBox();$('a[href$=gif]:has(img)').lightBox();$('a[href$=bmp]:has(img)').lightBox();});
//]]>
</script>
Step 5. Click on the "Save template" button to save the changes.

The final step is to disable the original Blogger Lightbox so that it doesn't interfere with this one that we just added: go to "Settings" > "Posts and comments" and you will see the "Showcase images with Lightbox" section on the right side > select "No" and click on the "Save settings" button on the upper right side.

disable blogger lightbox

Now, view your blog and click on any image to see the Custom jQuery Lightbox for Blogger in action. Enjoy!

How to Use Cookies in Javascript

Each time we visit a website, cookies can be stored to 'remember' things that we do while browsing a page. This may happen, for example, when we visit a page where we have to login with an username and a password. In this case, after verifying that the login is correct, usually a cookie is stored on our computer.

An example would be the popular page of Google. This search engine allows users to choose how many search results they want to see on each page. Thanks to a cookie, this configuration remains unchanged for each computer, even after rebooting several sessions. Despite this, it is good to remove them from time to time because although some will expire being erased automatically after a while, some of them will never do so.
cookies with javascript, blogger tricks

Like many other things, cookies may suffer a poor use and hence, their bad reputation. For instance, some websites can store and study the browsing habits of a user without their knowledge. This is why most browsers already include a system to filter them and can decide if they will provide some privacy or not.

If you want to see a live example of how a cookie works, please visit this page and refresh it a few times. You should get an alert window telling you about how many times you visited the page.

Script source: javascriptkit.com

There could be other ways to use cookies but a server could do this with JavaScript. Below we have a simple script that can be used as many times we want, even for different purposes. Basically, what the following script does is to create three functions: the first one is to set a cookie, the second one is to read it, and the last one is to erase it. We can apply it in Blogger by accessing the template HTML and add it just before the </head> tag:
<script type='text/javascript'>
//<![CDATA[

// Set cookie
function setCookie(name, value, expires, path, domain, secure) {
document.cookie = name + "=" + escape(value) +
((expires == null) ? "" : "; expires=" + expires.toGMTString()) +
((path == null) ? "" : "; path=" + path) +
((domain == null) ? "" : "; domain=" + domain) +
((secure == null) ? "" : "; secure");
}

// Read cookie
function getCookie(name){
var cname = name + "=";
var dc = document.cookie;
if (dc.length > 0) {
begin = dc.indexOf(cname);
if (begin != -1) {
begin += cname.length;
end = dc.indexOf(";", begin);
if (end == -1) end = dc.length;
return unescape(dc.substring(begin, end));
}
}
return null;
}

//delete cookie
function eraseCookie (name,path,domain) {
if (getCookie(name)) {
document.cookie = name + "=" +
((path == null) ? "" : "; path=" + path) +
((domain == null) ? "" : "; domain=" + domain) +
"; expires=Thu, 01-Jan-70 00:00:01 GMT";
}
}

//]]>
</script>
Once done, in order to set a cookie, we only need to put the name and the value in quotes when we call the function. Additionally, we will set the expiry date by getting the current Time (in milliseconds) and add the required number of minutes (in milliseconds):
var expiration = new Date();
expiration.setTime(expiration.getTime() + 10000); //Expire after 10 seconds
setCookie("cookiename","hello",expiration);
}
The above code sets a cookie called cookiename, with the hello value and set its expiry date to 10 seconds after it has been set (10000 milliseconds = 10 seconds). If we want to restore the value of this cookie, then we should use the second function with the cookie name:
var checkCookie = getCookie("cookiename");
By adding this code below the <body> taag, we created a cookie with the value 'hello' which can be shown on the screen if we want to. The cookie will disappear after 10 seconds:
<script type='text/javascript'>
var expiration = new Date();
expiration.setTime(expiration.getTime() + 10000);
setCookie("cookiename","hello",expiration);
var checkCookie = getCookie("cookiename");
document.write(checkCookie);
</script>
The erase function is used in the same way as the one for reading just by clicking on the name of the cookie. The setCookie values for 'domain' and 'secure' are not used. Use 'domain' on the JavaScript cookie if you are using it on a subdomain, where the cookie is set on the widgets subdomain, but you need it to be accessible over the whole yoursite.com domain.

The combination of these three functions will allow us to handle cookies for specific purposes, as we will see in the near future.

Saturday, 8 March 2014

How to Add CSS code To Blogger using Template Designer

If you are having difficulties adding the CSS codes in a Blogger template, here's a short guide that will show you a more practical and fast way to add CSS (Cascading Style Sheets) so that it will be easier for you to customize your blog.

Some users have complained that when they had to add the CSS codes to install some feature in Blogger, they found it difficult to locate the ]]></b:skin> tag. So, I decided to make this quick tutorial to show you another way of adding the CSS without having to access the Blogger HTML editor.

Adding CSS via the Blogger Template Designer

Step 1. Log in to your Blogger account and select the blog that you want to customize.

Step 2. From the Blogger dashboard, choose "Template" and click on the "Customize" button.


Step 3. Click on the "Advanced" tab.

Step 4. Now just add your CSS code inside the "Add CSS" tab (if you have more options, you may need to scroll down the list). Here you can add any CSS code each time you want to apply a new style to your template.


Step 5. Once added, click on the "Apply to blog" button to save the changes.

Following this method, you can't edit the existing CSS styles already added in your template which will require to access the template's HTML and make the modifications there. Here, you can only add new styles and edit the existing styles added through the Blogger Template Designer panel.

Please note that when adding the CSS styles, there's no need to put the <style type="text/css"> ... </style> style tags, which usually would go above the </head> tag in the template's HTML code. Adding these tags may result in an error.

If you change the template, the CSS added here will be removed. The same goes for any other additions or CSS customizations made ​​through the template HTML editor. So this is how we can easily add CSS code to Blogger using Template Designer without having to search the ></b:skin> tag.

HostGator Review and Current HostGator Coupon

HostGator Review

If you’re in search for that perfect web hosting solution for your business website or personal blog, than HostGator is the host for you.  HostGator is providing their reliable web hosting services at the affordable rate of $7.16 per month.  However, if you’re new to HostGator you can take advantage of their latest web hosting coupons, discounts, or promo codes.  These promotional opportunities will lower the already low rates down to $3.96 per month for new HostGator customers.  If you’re just looking for these discounts instead of the review, than you can find these promotions all throughout our website.

As the best HostGator review site on the Web, we have been working 24/7 to bring you the most informative information possible so you can make the right web hosting choice.  We would also like to point out that are research and reviews are based on first hand experience as we are hosting this very website with HostGator.  If you find our HostGator review beneficial please feel free to follow us on twitter @mybloggerhelper to catch our web hosting news.

HostGator Review and Current HostGator Coupon

HostGator Coupon

Before you make the commitment to HostGator financially, be sure to claim the new HostGator Coupon Code and Coupons.  These promo opportunities will save new HostGator customers over $3 each month on their web hosting purchase.  The coupons can be activated by clicking on any of our promo links or HostGator coupons that redirect users to current HostGator promo page.  HostGator coupon codes are used by entering the code during the sign-up process.  Below you can see the best possible HostGator coupon codes for $10 off, 25% off shared web hosting and $25 off reseller packages.

Top Three HostGator Coupon Codes

25% OFF HostGator Web Hosting – [ 25fatwallet ]
$10 OFF HostGator Web Hosting – [ 1centhoost ]
$25 OFF HostGator Reseller Hosting – [ younesokok ]

HostGator Coupon


For those who are looking for something a bit different than what HostGator has to offer should remember we’re also providing coupons for all of the top hosting providers.  These reviews and discounts can be found at the top navigation bar or on the right sidebar.  By taking advantage of these special rates, new web hosting customers will save anywhere from 40% to 60% on their next hosting purchase.

HostGator Features

If you’re looking to out shine your competitors on the Web, then it’s crucial to have a web hosting provider that offers the best features.  HostGator has been offering their services to perfection ever since opening for business in 2002, hosting over 8,000,000 domains world-wide.  Below you can see the features that separate HostGator from the rest.  HostGator received a 10/10 for their features rating.
  • Unlimited of Domains
  • Unlimited of Hosting Space
  • Unlimited of File Transfer
  • Unlimited of E-Mail Accounts
  • Anytime Money-Back Guarantee
  • Free Domain Name
  • Free Site Builder
  • Free $100 Google Adwords Credit
  • Free Statistic Tracker
  • 24/7 Customer Support
Obviously HostGator is offering one of the best overall web hosting packages on the Web.  The value HostGator brings to the table is just unmatched, making the features just one of the many reasons we’re hosting our site with HostGator.  Due to the fact HostGator offers a money-back guarantee makes it clear they have confidence in the services being provided.

HostGator Plan

HostGator is the best option for those needing a business website, e-commerce website, or personal blog.  For those that didn’t notice the unbelievable amount of features listed above, HostGator is implementing value into every single hosting package.  Each HostGator plan includes free access to their website builder.  The website building tools are a perfect way for those without any prior computer skills to create a website.  This is an excellent alternative to have your very own website up in a matter of just minutes!
Future HostGator customers looking to lay claim to the most affordable rates on the Web will most definitely want to sign up for a three year plan.  The three year HostGator plan enables users to maintain their discount rates for a much longer period of time.  The reason this is the best path to take when signing up, is that existing HostGator customers aren’t given the option to use coupons or coupon codes during the renewing stage.  Unfortunately, most web hosting customers are unaware and believe that just because they are receiving the cheaper rates at that given time they’re saving the most money.  With that being said, it’s very important to plan ahead and maximize your savings by selecting the three year plan at the initial sign-up if you can afford it.

Wednesday, 5 March 2014

How to add custom Variable definitions to Blogger

In this tutorial, we are going learn about the CSS Variable Definitions for Colors and Fonts that could be found at the top of the style sheet of a Blogger blog. The values for the Variable definitions can be modified directly through the Blogger Template Designer where are the settings for colors, backgrounds, fonts and font sizes.
blogger variable definitions

Most default Blogger templates, such as the Minima Template, use these settings for the CSS, which makes it easier to modify the variables through the Blogger dashboard, using the Template Designer ("Template" > "Customize") editor and going to the "Advanced" section.

blogger template designer, variable definitions

If the definitions are already added in the CSS, we'll be able to change the background colors, font colors, styles or sizes, directly from our Blogger dashboard without having to touch the HTML code of our template.

If these values ​​are not set, we can define them by creating our own variables. The more variables are created, the greater will be the ease of changing colors and fonts of the Page Elements by going to the "Template Designer" and click on the "Advanced" tab.

In some cases, we can't change the color or font of a custom template if the designer has not implemented the variables and didn't defined & specified a particular value directly into a property. And if there is no definition for these values​​, we may not be able to customize it through the Blogger's Template Designer.

There are two types of variables:

1) Color Variable:
<Variable name="body.background.color" description="Outer Background" type="color" default="#66bbdd" value="#66bbdd"/>
  • In red is the variable name. Here you can put any name you want, however, it must not contain spaces, that's why we may see some variable names using a dot "." between each word.
  • In green is the description that will appear in the Fonts and Colors panel (it can contain spaces).
  • In blue is variable type, which in this case is "color".
  • In purple is the default value, which runs in the absence of any other value.
  • In orange is the value of the selected color.
2) Font Variable:
<Variable name="body.font" description="Font" type="font" default="normal normal 12px Arial, Tahoma, Helvetica, FreeSans, sans-serif" value="normal normal 12px Arial, Tahoma, Helvetica, FreeSans, sans-serif" />
  • In red the variable name without spaces.
  • In green the description of the variable, may contain spaces.
  • In blue is the type of the variable, which in this case is font.
  • In purple the default font.
  • In orange is the font that you choose.

Where Are Variable Definitions located

We can find the variables definitions in the <head> section of our Template by accessing the HTML code (click on the "Edit HTML" button). There we should see a pair of <b:skin>..</b:skin> tags. The CSS style declarations will go in between those tags, along with the variable names.

variable definitions

How to Create Variables with type Color

Now, let's see how we can create type="color" variables in our template.

Please copy the below snippet and replace the names and types as you like, then paste the code below this comment:
/* Variable definitions
   ====================
Code to copy:
 <Variable name="NAME" description="DESCRIPTION" type="color" default="#xxxxxx" value="#xxxxxx" />
For a better understanding, let's take a look at this example with variable of type "color":
<Variable name="variablecolor" description="Variable with light blue color" type="color" default="#DDF2FF" value="#DDF2FF" />
color variable type

Here, I have created a variable of type "color", with the "variablecolor" name. The color values (#DDF2FF) can be applied to all the borders of my blog and whenever I want to apply color styles to a specific border, I will type it like this:
border: 1px solid $(variablecolor);
Note that I have added the "$" symbol before the variable's name and included the name inside the parentheses. These should be added every time you want to implement a new variable definition.

Once we have created the variable, we can apply it on any property (not only borders) of any selector (page element) where it is possible applying the chosen color.

For example, if I want to add this color in the main-inner background (sidebar and posts area), I will add it just after the "main-inner" class selector, like this:
.main-inner {
background-color: $(variablecolor);
}
variable type color, variable definitions

Now that a new variable has been added, save and return back to the blogger dashboard by clicking on the "Customize" button, then the "Advanced" tab. You will notice that there is a new variable called "Variable with light blue color". In order to change the color, just use the color picker tool.

blogger template designer

How to Create Variables of type Font

Now let's say that I want to create a new variable of type="font" which I want to apply on the title of the sidebar gadgets. I will add it this way:
<Variable name="gadgetstitlefont" description="Gadgets Title Font" type="font" default="normal normal 16px Arial,Verdana,'Trebuchet MS',Trebuchet,Sans-serif"  value="normal normal 20px Cambria"/>
In this variable that I just created, the default font to be searched by the web browser should be Arial, and in its absence, Verdana and so on. Otherwise, apply the Cambria font which is actually the font that we want and which can be easily changed by accessing the Blogger Template Designer.

Once the font variable has been implemented, we can add it to any property of any selector where we want to define this font style.

To define where this variable should be applied (which, in my example, is the title of the sidebar gadgets), I will need to include the values ​​directly in the "h2" property of the "sidebar" selector (sidebar-right-1), by creating the following CSS rule:
#sidebar-right-1 h2 {
font: $(gadgetstitlefont);
}
And I will add this above the ]]></b:skin> tag of the Template (don't forget to add the "$" symbol before the variable's name, also put the name between the parentheses, otherwise it won't work).

variable font type

Now, that we have included a new variable, Save the template and return to the Blogger dashboard by clicking on the "Template" > "Customize" button and access the "Advanced" tab. Scroll down and we will see a new variable named "Gadgets Title Font" - if you want to change the font type or size, you can do it directly via this panel.

variable font type advanced

After you've decided what font style should be applied, click on the Apply to blog button on the right side.

apply to blog button

As you work on your template design, you can add lots of color and font variable types, however, for other types of CSS attributes, it is not necessary to create variables. The other types, such as margin, padding, need to be included in the HTML of the template above the ]]></b:skin> tag. So that's how you can add custom variable definitions to Blogger. Enjoy!

Sunday, 2 March 2014

Understanding the Page Elements of a Blogger Layout

When following a tutorial on how to add a gadget/widget or make some customizations in a Blogger blog, some new users may not know the meaning of certain terms, and it may be harder to locate them. As for the gadgets, usually it is required to access the blog's layout in order to add or arrange any of the page elements.

For a better understanding, here are some basic explanations about the Page Elements located in the Layout section of a Blogger dashboard.

What are the Page Elements?

Page Elements is, basically, the body of our blog. To access the Page Elements, we need to click on the "Layout" option in the Blogger dashboard.


Understanding the Page Elements sections

The Blogger Layout is made of sections and elements. The sections mark certain areas of a page. Every section is represented by the <b:section> tag and has an unique "ID" that names its element which is followed by a CSS "class" selector. Each section has some attributes and through these, we can determine the number of elements allowed in the section and if this section gives the option to add a "page element".


Let's take a look to an example of the default code related to the header section found in the HTML of a Blogger template:
<b:section class='header' id='header' maxwidgets='1' showaddelement='no'>
<-- rest of the code -->
</b:section>
Breaking apart the code above:
  1. <b:section is the opening tag of the section.
  2. class='header' - describes the existing group inside the "header" element
  3. id='header' - identifies and specifies the header as a single element.
  4. maxwidgets='1' - determines the number of elements allowed in the "header"; here we have the number of gadgets that we can include in the header section. In this example, '1' means that this section allows us to add only a gadget.
  5. showaddelement='no' - the 'no' attribute means that the header will not show the "Add a gadget" link or we won't be able to move any Page Elements. To activate this option so that we can add new Page Elements (Add a gadget), we should change 'no' to 'yes'. By setting the "showaddelement" attribute to 'yes', we'll be able to arrange the elements as we like, just click on the element that you want to move and drag & drop it wherever you want.
The spaces reserved for adding elements in the existing sections are called Gadgets (or Widgets). You can easily add various Page Elements by clicking on the "Add a Gadget" link. This will open a pop-up window for you to pick and choose which elements should be added. Just click on the Gadget's title or on the blue plus sign symbol to add it to your blog's layout.


After you have added a page element, gadgets can be moved up, down or sideways. You can put them wherever you want. Of all the existing gadgets, the most used is the "HTML/JavaScript". Inside this gadget (widget) you can insert any code, as long as it is in the HTML or JavaScript language.

Each time you decide to add a new gadget, click on the "Add a gadget" link in the area where you want to add it. For example, if you want to add a JavaScript code and want it to appear in the sidebar, you should click on the "Add a gadget" link in the "Sidebar" section, choose the "HTML/JavaScript" option and paste the code in there.

Once you have added new gadgets (widgets), it is recommended to check the changes by clicking on the Preview button before saving anything. So, if something went wrong, you simply click on "Clear" and everything that was not saved will return to its previous state. If the position of any Page Elements (Gadgets) has been rearranged, you will need to click on the Save arrangement button in order to see the changes.