You are viewing limited content. For full access, please sign in.

Question

Question

How do I center text within a single line field?

asked on December 1, 2015 Show version history

I'm trying to center the number 8 here:

I keep changing the alignment of the field as a whole, instead of just the number within.

 

Thanks

0 0

Replies

replied on December 1, 2015

Hey David,

It sounds like you're selecting the whole field, instead of just the input.  Try this:

#q26 input {text-align: center;}

Where #q26 = your Field #

1 0
replied on December 1, 2015

This is exactly what I was needing.

 

Thanks!

0 0
replied on December 1, 2015

Use text-align. Add this to your "CSS and Javascript">"CSS" section of your form.

input.singleline { text-align:center;}

This will center ALL your input's text. I would suggest to name your fields or give your fields classnames, then you can reference just that singular field.

0 0
You are not allowed to follow up in this post.

Sign in to reply to this post.