Bug Tracker

Opened 9 years ago

Closed 9 years ago

Last modified 8 years ago

#7466 closed bug (invalid)

autoFill input doesn't work with Google Chrome

Reported by: remy.burney@… Owned by:
Priority: undecided Milestone: 1.5
Component: unfiled Version: 1.3.2
Keywords: Cc:
Blocked by: Blocking:

Description

I use the JavaScript function below to have a default text on my input field, but it doesn't work with Google Chrome. I just realize that I use the version 1.3.2, I didn't test the function with the latest version.

function autoFill(id, v){

	$(id).css({ color: "#b2adad" }).attr({ value: v }).focus(function(){

		if($(this).val()==v){

			$(this).val("").css({ color: "#333" });

		}

	}).blur(function(){

		if($(this).val()==""){

			$(this).css({ color: "#b2adad" }).val(v);

		}

	});

}

Change History (2)

comment:1 Changed 9 years ago by anonymous

You can see and example at http://www.saba.com.au/www/600/1001127/1154322.asp The input field is "Enter Suburb or Postcode" in that page.

comment:2 Changed 9 years ago by snover

Resolution: invalid
Status: newclosed

Thanks for the report, but 1.3.2 is over two years old. If you use the latest version of jQuery and this is still a problem and you can provide a reduction showing only the call that fails, please feel free to do so.

Also, you may want to learn about the html5 placeholder property.

Note: See TracTickets for help on using tickets.