placeholder style i wartości

taki sam placeholder dla każdego inputa w js:


$(document).ready(function(){ 
  $('form').find("input[type=textarea], input[type=password], textarea").each(function(ev)
  {
     if(!$(this).val()) { 
     $(this).attr("placeholder", "Type your answer here");
  }
  });
});

style dla placeholder, kolor tekstu:

/* Placeholder text color -- selectors need to be separate to work. */
::-webkit-input-placeholder {
	color: #686868;
	font-family: Montserrat, "Helvetica Neue", sans-serif;
}

:-moz-placeholder {
	color: #686868;
	font-family: Montserrat, "Helvetica Neue", sans-serif;
}

::-moz-placeholder {
	color: #686868;
	font-family: Montserrat, "Helvetica Neue", sans-serif;
	opacity: 1;
	/* Since FF19 lowers the opacity of the placeholder by default */
}

:-ms-input-placeholder {
	color: #686868;
	font-family: Montserrat, "Helvetica Neue", sans-serif;
}