Subscribe to the RSS Feed : Read our Blog Posts from the convenience of your favourite Reader

Optimizing CSS and Javascript

January 11th, 2011 . by Anup



Once you’re done optimizing images , you should work on CSS and Javascript files. One way to do this is by aggregating all your CSS files into one big CSS file and all your JavaScript files into one big Javascript file.

This helps reduce http requests which in turn leads to faster loading times for your website.

Another tip would be to delete redundant CSS declarations. Remove CSS declarations that are not in use.

Move CSS on top and Javascript to the Bottom.

CSS declarations or file includes should be in between the section. This way browsers will know how to display the page before they even get to the HTML .

JavaScript files belong at the bottom , right before the </body> tag.  This prevents JavaScript code from rendering the page while things are still being requested.

Minify CSS and JavaScript

We’re going to use Minify and JSLint for this next part.

Copy all your JavaScript onto the clipboard onto the corresponding input field in Minify.

Then click “Hit Me”. and use the resulting JavaScript on your website.

Minify – http://www.reneschmidt.de/tools/minify/

JSLint – http://www.jslint.com

Make sure you check the JavaScript once again after it is minified to ensure it is still working before replacing existing JavaScript files.

Making CSS and JavaScript External

It is considered good practice to not use inline CSS and JavaScript. Always have them in external files. That way they’re easier to edit, reduce the size of the page, cache easier and reduce load times which leads to a better user experience.

That brings us to the end of the optimizing JavaScript and CSS post.

Until Next Time.

GameTap - Buy and Download Hundreds of PC Hits!

Optimizing Images

January 7th, 2011 . by Anup



Building on the previous blog post on website optimization , this post is going to be on optimizing images on your site. If YSlow displayed that your images should not be scaled in HTML or make favicon small and cacheable, then this post is for you.

Correcting Dimensions in IMG tags

A lot of people do this. They use ,say an image that is 1200 x 784 pixels, they want displayed at 120×90. They then use html to scale it down. This practice works as in it displays fine but not on the optimization and site speed end. You see if you use Html to scale the images usually by using the img tag, transmitting the image will take a long time.

<img src=”something.png” alt=”something” width=”120″ height=”90″ />

There are a lot of tools out there which can help you do this. I personally use Paint.NET. Its free and easy to use. You can download it from http://www.getpaint.net/

You should resize any pictures or images you may add in the future using this program or your editor of choice. But ofcourse editing existing images on the website will take way too long and generally could be work.  We don’t need more work , we got plenty.

That brings us to our next step. Firefox’s YSlow comes with a tool called Smush.it Smush.it is our shortcut when it comes to image optimization. Reducing images, art, screenshots etc. would have been a lot of work otherwise.

How to use Smush.It

Open up Firefox .

Open up YSlow.

Under the YSlow tab, you should see four tabs on the top left. Click on Tools tab.

Click on All Smush.it™ . This should open a new window and you should see your images either being processed or optimized. You’re going to have to download them as .zip

Unzip them and upload the optimized images back to your server replacing the previous images. Preferably overwriting them. Repeat them for other pages of your site.

Info on using sprites to reduce emoticon load times for forums.

I’ve not looked into this much because it doesn’t apply to me . But an indepth explanation on how to use CSS Sprites to reduce load times can be viewed using the link below
http://sixrevisions.com/css/css-sprites-site-speed/

Content Delivery Networks .

This part can become an expensive affair. If you can afford this then by all means do so. It is worth the price and your website visitors will thank you for it. Now for the rest of us there are alternatives.

I use CloudFlare. It is a CDN that comes bundled FREE with a HostGator account. If your site is huge and the solutions that follow don’t help you out much , then I suggest getting a hostgator account to use cloudflare. Serving niches uses Cloud Flare. It is one of the many reasons I think anybody gets to see this Site. So it works wonderfully.

copyblogger.com uses http://www.netdna.com/ the Net DNA Content Delivery Network. So that could be another option you’d want to check out.

Googling “Content Delivery Network” should give you more options. I say this because I don’t too have much info what CDN’s the major websites use.  Bigger websites tend not to discuss their technology choices too much.

That brings us to the end of the Optimizing Images Blog Post. Next time we’ll look into working with CSS and Javascript on our pages to help optimize our website and entice visitors to stay longer.

Discover the World's largest E-Book Store! Save big on bestsellers!

Optimize Your Website Using YSlow

January 5th, 2011 . by Anup



Have a lot of people leaving your site too fast ? Your high bounce rates could be due to a slow loading website. People these days simply don’t wait for 5 or 10 seconds for a page to load.  A slow loading page affects everything else you do . You can say bye bye to those sales and leads. Therefore it is important that you optimize your websites. Lets forget usability or anything else that would affect sales. We’re going to concentrate on making your site more responsive i.e load faster. Want another reason ? Okay then .

Here’s something that happened to me a while back.Now serving niches is a relatively small site / blog. There are only a few 100 posts. You don’t exactly see it and expect it be heavy on the server.

As it turns out I had just deleted older posts which I thought were longer relevant and some I thought didn’t live up what we are trying to achieve here. Now as it turns out the blog was loading a bit faster after I had deleted a lot of older posts, atleast I thought so.  I felt content and logged out.

Next day I check my email and there’s an email from my hosting provider.

First I sit there and scratch my head thinking what on earth could they be emailing me about on this day of the week.

Turns out my small site was so slow loading and so heavy on resources and the server, it was starting to affect the other sites on the server. So they had to temporarily suspend my account and stop all traffic to it until I speed it up.

Needless to say I was shocked. Well okay first I was confused and then I was shocked. My teeny blog is causing problems ? So they agreed to let me in provided I fix stuff or lease out an entire server. Of course they weren’t exactly going to throw me out. There weren’t going to let in any traffic unless I had fixed the problem.

That is where YSlow came to the rescue. I ran it and well it gave me an F . But it also told me how to go about fixing the blog and site .

The next few blog posts are going to be all about Website and Blog Optimization. First we’ll begin with Yslow. We’re going to take it a bit further than that in later blog posts. But first YSlow.

Today is the simplest part . Installing Yslow and related Components.

You need to get the Firefox Browser first . Download the browser from http://mozilla.org and install .

Now you need the firefox browser and and add on called firebug. YSlow is  a plug in for Firebug. Firebug is pretty cool itself but its features are out of the scope of this blog post. Back to installing YSlow.

Go to http://www.getfirebug.com and install Firebug

Then go to https://addons.mozilla.org/firefox/addon/5369 to install YSlow

Once all these are installed , You are now ready to run Yslow. Restart your FireFox Browser.

You should see something like the picture below at the bottom right of your firefox browser.


Once you have restarted Firefox, open your website.

Go to “Tools > Firebug > Open Firebug”.

A split window should open . Click YSlow . Choose appropriate Ruleset. It doesn’t really matter .

It will analyse your website and give you a grade.

We’re going to work on improving that Grade in the next blog post.


To learn more about Firebug check out

http://www.packtpub.com/article/installation-and-getting-started-with-firebug

Get Unlimited Access to Hundreds of Games

Build A Free Survey’s Website

December 30th, 2010 . by Anup



First off I have to mention this. To get a digest of Serving Niches’s valuable posts in one easy to read PDF , go here.

The link will take you to a Landing Page where I talk a bit about the new ebook I’m going to be putting out very soon. Sign up to the list to get it for FREE when it becomes available.

You guessed it . I’m currently building up a list to build up interest for this valuable ebook.

A survey website is perfect for the beginner or anyone else. It is easy . Of course there is no such thing as a sure shot. But this ebook does its best. It discusses how to build one around the powerful membership site business model. There is unfortunately a bit of work when it comes to building one. Most marketers I’ve seen mention this don’t tell you how to go about building one. It isn’t easy if you don’t know how. Not to mention have any applicable strategy .

I mention how anybody can go about building one.

Also :

Why the membership business model is amazing .

Where to get Surveys for FREE .

And of course when I mean building a Survey Website I mean building a survey site that makes you money.

So click here to go sign up to the list if you would like to find out how.

$5 off orders of $30 or more at GoDaddy.com Go Daddy Website Hosting Get Unlimited Access to Hundreds of Games

Subscribe and Receive Updates via Email

December 23rd, 2010 . by Anup



Subscribe to receive updates from Serving Niches via email. Email subscribers also get FREE reports and offers not available elsewhere on the site when available. Subscribe today . It’s free.

Get Unlimited Access to Hundreds of Games

« Previous Entries     Next Entries »