Tuesday, December 22, 2009

ways to Speed Up your Page Response Times.

Its ok with if we develop any web application, but it you speed up your application in right manner then you will be a charm of web. users requirement is they want to see your application page as quickly as , but if your application is time consuming from all the aspect then surely no one will stay on with your site. here i got some nice and simple techniques which will improve your page speed from all the aspect. now google also setting this as a basic criteria.

Now you all knows mozilla has some good addon call "Firebug" you can install that plus you can also install ""Google page Speed " which will tell hows your application is behave . there is one more useful addon by yahoo is "YSlow" .



from this addons you will get lot of information , also try this
1. Load your CSS first and your JavaScript last
Load your css in <head > tag above your body . and try to load your javascript above the closing the body tag.

2. Using Sub domains for parallel downloads
This is like cool one , on your site that are lot many static and dynamic images , you can identify that what are the static and what are the dynamic and according to that you can set your sub domain which will useful for parallel download ,so the time requires to download a single image will be get converted into parallel server and parallel image get download from your one of the server .The ideal case is you can set max of 3 server for same,

3. Minify JS and CSS:
Again size get matter , means one your page if you keep unwanted space on js & css surly size get increase, in this case you can reduce that and make them as lighter as possible, if you use above tools they will give you option how to inimize this or minimize version of same.

4. Avoid redirects:
No matter if you do a server-side header redirect, JS,HTML redirect, your site is going to load a header with a blank page, then load your new page, increasing the time it takes for a user to get to the actual page they want to go to

5. Using CSS Sprites to reduce HTTP Requests
CSS Sprites may be the coolest thing, it get reduce your page loads and also reduce the amount of request for each particular images. now look at below you can see one image (static one) contain 15 + images now using CSS you can cut that according to your requirement (using Padding and all )
and use that as you want.
Best example you can see is " YouTube CSS Sprite ".



define that like this way:


< style >
.sprite {
background:url(http://s.ytimg.com/yt/img/master-vfl87445.png);
}

#logo {
width:100px;
height:45px;
background-position:0 0;
}
</style >

<div id="logo" class="sprite"> </div>



That was a lot of stuff, but hopefully you picked up a few tips on how to make your web pages load faster. if you know more on this
add it on comments .

Thursday, December 17, 2009

Traversing an Html table with Javascript

This article will introduce you on how to get html table content using DOM Inteface, ones we create an Table on html and suppose we need to retive that table content on server side, on any purpose then this will helps you.you can refer this its really nice way to parse the html table and get the content on same .

mozilla developer has given a good link on ,how to create a DOm interface for table structure

sample example:
1. lets create a Table

<table>
<tbody>
<tr> <td> This is first td </td></tr>
<tr> <td> This is second td </td></tr>
<tr> <td> This is third td </td></tr>
</tbody>
</table>


2. now create a Dom inteface to read this table content , for that you can use Javascript to read this

<script >
function start() {
// get the reference for the body
var body = document.getElementsByTagName("body")[0];

// creates a <table> element and a <tbody> element
var tbl = document.createElement("table");
var tblBody = document.createElement("tbody");

// creating all cells
for (var j = 0; j < 2; j++) {
// creates a table row
var row = document.createElement("tr");

for (var i = 0; i < 2; i++) {
// Create a <td> element and a text node, make the text
// node the contents of the <td>, and put the <td> at
// the end of the table row
var cell = document.createElement("td");
var cellText = document.createTextNode("cell is row "+j+", column "+i);
cell.appendChild(cellText);
row.appendChild(cell);
}

// add the row to the end of the table body
tblBody.appendChild(row);
}

// put the <tbody> in the <table>
tbl.appendChild(tblBody);
// appends <table> into <body>
body.appendChild(tbl);
// sets the border attribute of tbl to 2;
tbl.setAttribute("border", "2");
}
</script >


3. This javascript will first read the table tag element and search with tbody and tr then next td and retrive the content on same .

4. Remember this technique. You will use it frequently in programming for the W3C DOM. First, you create elements from the top down; then you attach the children to the parents from the bottom up.

5. Its create just like this way .

Thursday, December 10, 2009

Facebook and MySpace deals with Google for real-time search



Yes, Myspace and FaceBook have signed with Google for the Real-Time search giant.
Facebook and MySpace both are very popular Networking as well as Social bookmarking site, with contain huge amount of Data as well as Traffic too.

so with the Help of that data Google may give you better result and better Search , Till now we know google deal with Twitter but now they also deal with FaceBook and MySpace . Which means if someone get Search on any Topics then they also get the Real - Time Updates for this social media sites ,

This has led to Both Google as well as Bings .in Order to make there search result very faster adn exact. On recent interview with Tom Stocky Google Director of Product Management. he is saying "People are crazy about the Search and they want up-to-date search result what they looking for " they also said people are also looking for Search result as well as the result come is must be fresh , so surely this Process will help to make google better.

Google would not reveal the financial terms of its agreements – however Facebook’s chief operating officer, Sheryl Sandberg publicly stated at Web 2.0 in San Francisco, that it would be making no money from making public status updates available to search engines. However, MySpace and Facebook have not revealed similar details.

But In Order with Bings they still has to Integrate the search with Twitter into search Process, they also come up with new separate site with "tweets". lets hope it will come soon.

Thursday, December 3, 2009

Google Audio indexing

Google get introduce new technology call Google Audio Indexing (Gaudi) . which allow the user to better search from video point of view. It basically using Speech technology to find out the Exact word inside that video and jump the user according to that world where these words get spoken.

Basically you all know words,sentence, text can get search easily, but this is really nice way to search the text from video itself. which will give your result more additionally.

How you can use this :
Look at the below pics you can get ,



if i want to search related with gas prices it will show you result on where exactly this word get spoken on various videos. on left hand side you can see there are Channel filters you can even though filter your search by clicking on that tab . and right hand side you can see there is one video call Gang of 10 and on that video , after particular period some yellow dots are there they are mentioning where exactly that word get spoken, you can directly move your cursor at that position and listen that word. and at bottom its shows various pages result.

You can also Share this videos with your friends just clicking share button on that video . or simply copy-paste that URL also.

one more thing you can only search the videos from Youtube source only.
if you want to know how its works look at this : http://labs.google.com/gaudi
Currently this technology its in Google Lab , it will publish soon.