Jump to content

Submit value not showing !!


RobertP

Recommended Posts

Look in scripts.js:246-259:

	$("input,textarea").each(function(){
	placeholder = $(this).attr("placeholder");
	if(placeholder=="undefined"||placeholder==false||$.browser.msie=="undefined"||!$.browser.msie)
		return;
	$(this).val($(this).attr("placeholder"));
	$(this).focus(function(){
		if($(this).val()==$(this).attr("placeholder"))
			$(this).val("");
	});
	$(this).blur(function(){
		if($(this).val()=="")
			$(this).val($(this).attr("placeholder"));
	});
});

Debug that "placeholder" variable...

ok, thank you so much, but, now how do i add placeholder support to ie?

 

EDIT:: never mind, i fixed my selector LOL

 

$("input[type=text],textarea").each(function(){
	placeholder = $(this).attr("placeholder");
	if(placeholder=="undefined"||placeholder==false||$.browser.msie=="undefined"||!$.browser.msie)
		return;
	$(this).val($(this).attr("placeholder"));
	$(this).focus(function(){
		if($(this).val()==$(this).attr("placeholder"))
			$(this).val("");
	});
	$(this).blur(function(){
		if($(this).val()=="")
			$(this).val($(this).attr("placeholder"));
	});
});

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.