Grab the RSS feed

Create a expandable Text area like face boook

Hi friends if you see the text area in face book for replying message it going to be nice and good one.


It is going to be expand for particular distance after that only it going to make the scroll bar.You can also make this by using Jquery.

Here is the code for HTML

< !DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd" > 
< html xmlns="http://www.w3.org/1999/xhtml" > 
< head > 
< meta http-equiv="Content-Type" content="text/html; charset=utf-8" / > 
< script type="text/javascript" src="jquery/jquery-1.3.2.min.js" > < /script > 
< !--< script type="text/javascript" src="jquery.autogrow-1.2.2/jquery.autogrow.js" > < /script > -- > 
< script type="text/javascript" src="jquery/autoextendtextarea.js" > < /script > 
< title > Untitled Document< /title > 
< script > 
$(document).ready(function(){
$('textarea#comment').autoResize({
// On resize:
onResize : function() {
$(this).css({opacity:0.8});
},
// After resize:
animateCallback : function() {
$(this).css({opacity:1});
},
// Quite slow animation:
animateDuration : 300,
// More extra space:
extraSpace : 40
});
});
< /script > 
< /head > 

< body > 
< textarea style="line-height:10px min-height:30px" id='comment' > < /textarea > 
< /body > 
< /html > 


The Jquery Plugin for this is
// JavaScript Document
/*
* jQuery autoResize (textarea auto-resizer)
* @copyright James Padolsey http://james.padolsey.com
* @version 1.04
*/
//Source:http://james.padolsey.com/javascript/jquery-plugin-autoresize/
(function($){

$.fn.autoResize = function(options) {

// Just some abstracted details,
// to make plugin users happy:
var settings = $.extend({
onResize : function(){},
animate : true,
animateDuration : 150,
animateCallback : function(){},
extraSpace : 20,
limit: 1000
}, options);

// Only textarea's auto-resize:
this.filter('textarea').each(function(){

// Get rid of scrollbars and disable WebKit resizing:
var textarea = $(this).css({resize:'none','overflow-y':'hidden'}),

// Cache original height, for use later:
origHeight = textarea.height(),

// Need clone of textarea, hidden off screen:
clone = (function(){

// Properties which may effect space taken up by chracters:
var props = ['height','width','lineHeight','textDecoration','letterSpacing'],
propOb = {};

// Create object of styles to apply:
$.each(props, function(i, prop){
propOb[prop] = textarea.css(prop);
});

// Clone the actual textarea removing unique properties
// and insert before original textarea:
return textarea.clone().removeAttr('id').removeAttr('name').css({
position: 'absolute',
top: 0,
left: -9999
}).css(propOb).attr('tabIndex','-1').insertBefore(textarea);

})(),
lastScrollTop = null,
updateSize = function() {

// Prepare the clone:
clone.height(0).val($(this).val()).scrollTop(10000);

// Find the height of text:
var scrollTop = Math.max(clone.scrollTop(), origHeight) + settings.extraSpace,
toChange = $(this).add(clone);

// Don't do anything if scrollTip hasen't changed:
if (lastScrollTop === scrollTop) { return; }
lastScrollTop = scrollTop;

// Check for limit:
if ( scrollTop >= settings.limit ) {
$(this).css('overflow-y','');
return;
}
// Fire off callback:
settings.onResize.call(this);

// Either animate or directly apply height:
settings.animate && textarea.css('display') === 'block' ?
toChange.stop().animate({height:scrollTop}, settings.animateDuration, settings.animateCallback)
: toChange.height(scrollTop);
};

// Bind namespaced handlers to appropriate events:
textarea
.unbind('.dynSiz')
.bind('keyup.dynSiz', updateSize)
.bind('keydown.dynSiz', updateSize)
.bind('change.dynSiz', updateSize);

});

// Chain:
return this;

};



})(jQuery);


Here all the credits go to Source:james.padolsey

Leave the comment to improve us

CountdownTimer Using Jquery

Hi friends,

In this tutorial I am going tell about how to create and use th countdown Timer using Jquery.

In one of application the client want to display the count down timer.For that I choose Jquery and put it in my application.

The original count down timer is get from David walsh

I slightly modify it and give it to you.

First you need to put the Jquery plugin...


/*
Class:     countDown
Author:    David Walsh
Modified by:Vinoth Kumar.S
Version:   1.0.0
Date:      FEB 05 2010
Built For:  jQuery 1.2.6
*/

jQuery.fn.countDown = function(settings,to,id) {
settings = jQuery.extend({
startFontSize: '36px',
endFontSize: '12px',
duration: 1000,
startNumber: 60,
endNumber: 0,
myid:id,
callBack: function() { }
}, settings);
return this.each(function() {
//alert(settings.toString);
//where do we start?
if(!to && to != settings.endNumber) { to = settings.startNumber; }
//alert(settings.id);


//set the countdown to the starting number
//$(this).text(to).css('fontSize',settings.startFontSize);

hours = Math.floor(to / 60);
minutes = Math.round(to % 60);
if (minutes < 10) {
minutes = "0"+minutes;
}
$(this).text(hours + ':' + minutes).css('fontSize',settings.startFontSize);
//loopage
var myhour=hours + ':' + minutes;
$.cookie('test',myhour,{expires:7,path:'/'});

$(this).animate({
'fontSize': settings.endFontSize
},settings.duration,'',function() {
if(to > settings.endNumber + 1) {
$(this).css('fontSize',settings.startFontSize).text(to - 1).countDown(settings,to - 1);
}
else
{
$.cookie('test',null,{path:'/'});
settings.callBack(this);
}
});

});
};





Then create the Html Page

< !DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd" > 
< html xmlns="http://www.w3.org/1999/xhtml" > 
< head > 
< meta http-equiv="Content-Type" content="text/html; charset=utf-8" / > 
< title > countdowntimer< /title > 
< style type="text/css" > 
@import "jquery.countdown.package-1.5.5/css/jquery.countdown.css";

#defaultCountdown { width: 240px; height: 45px; }
< /style > 
< script type="text/javascript" src="jquery/jquery-1.3.2.min.js" > < /script > 
< script type="text/javascript" src="jquery/countdownplugin.js" > < /script > 
< script type="text/javascript" src="jquery/cookie.js" > < /script > 
< script type="text/javascript" > 
$(document).ready(function() {

$('#countdown').countDown({
startNumber: 25,
callBack: function(me) {
$(me).text('All done! This is where you give the reward!').css('color','#090');
$.cookie('test',null,{path:'/'});
//$(this).text(hours + ':' + minutes).css('fontSize',settings.startFontSize);
},
id:5
});
});
< /script > 
< /head > 

< body > 

< p style="border:1px;margin:auto 0px;text-align:center;margin-top:250px;" > 
< span id="countdown" > < /span > 
< /p > 

< /body > 
< /html > 




Please use this and leave the comment to us

change google look and apperance

Hi friends,

Today i am going to teach how to edit/delete google home page contents.Its really a working example and I used it and make fun.
How long we are watching the same google home page.If you get really bored you can do this.And prove you are a hacker.

Eventhough you doesnt want to prove a hacker make a fun with google.
You can apply this trick for any websites you want to do.

For that you need to do only two things.

1.Enter the web address you want to do edit

2.In browser please put the following javascript and hit enter.

javascript: document.body.contentEditable= "true"; document.designMode= "on"; void 0

Now enjoy yourself

Leave the comments to improve us

Best designed web sites

Hi friends,
In this post I am going to tell about the sites that contains the beautiful design for websites.
Most of the webdesigners facing the problem in choosing the color combination.But the following websites gives the real beautiful designing ideas.
I really suggest you,dont copy the things.But you can gather their ideas and implement it in your own way.It gives the lot of beautiful things tothe world.
Some of the sites also recommended for programmers also.
Why the programmers need te effort in designing?

Once the design is completed the programmers going to be develope the whole site for few days to few months...

If it is intresting thing then only they are watching watching the site upto the months....

so if you are going to be work with that site please give the small efforts on designs.It really helpful.


Best designed websites


1. onextrapixel

2. instantshift

3. ourtuts

4. webdesignbeach

5. ourtuts

6. httpwatch

7. bestcssdesign

for flash

8. webdesignstuff

Leave the comments to improve us.

Test Pay Per Post

The communist reflects!

Set Interval and Set timeout difference in Jquery

Set timeout in Jquery call the function only once.But the Set interval call the function again and again for the time limit we are given.
But if you want to make the websites such as update the user status and other things you are advice to use set time interval.

If you want to call a function after particular seconds(Such as delay) use the set time out function.

< !DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd" > 
< html xmlns="http://www.w3.org/1999/xhtml" > 
< head > 
< script type="text/javascript" src="jquery/jquery-1.3.2.min.js" > < /script > 
< meta http-equiv="Content-Type" content="text/html; charset=utf-8" / > 
< title > setTimeout/setInterval< /title > 
< script > 
$(document).ready(function(){
$("#settimeoutfunc").click(function()
{
alert('clciked,Please wait 20 seconds');
setTimeout('alert(\'Settimeout is cliked\')',20000);
});
$("#setIntervalfunc").click(function()
{
alert('clciked,Please wait 20 seconds');
setInterval('alert(\'SetInterval is cliked\')',20000);
});
//alert('test');
});
< /script > 
< /head > 
< body > 
< input type="button" value="settimeout" onclick="" id="settimeoutfunc"/ > 
< input type="button" value="setInterval" onclick="" id="setIntervalfunc"/ > 
< /body > 
< /html > 

 
Real Time Web Analytics