Sins97
Sins97

Reputation: 387

Placeholder text padding in firefox

I have a placeholder and I want to give padding to it. So far it's working in chrome but not in Firefox.

In Chrome enter image description here

In Firefox

enter image description here

there is no padding applied

This is my css

 .form-control::placeholder {
    font-size: 15px;
    padding-left: 15px;
  }


and for firefox

 .form-control::-moz-placeholder{
    font-size: 15px;
    padding-left: 15px;
  }

Upvotes: 1

Views: 66

Answers (1)

Terek Janczik
Terek Janczik

Reputation: 176

You can give the input padding as well to achieve the same effect. It is also going to have padding for when the user inputs text into the text box and not sit against the left border.

.form-control {
  font-size: 15px;
  padding-left: 15px;
}

Upvotes: 1

Related Questions