Select to view content in your preferred language

HTML text-align:center not working in label column of Note field

1466
4
Jump to solution
03-05-2025 11:04 AM
ZenMasterZeke
Frequent Contributor

Hi all. I'm having a problem formatting the label text in a note field using html. The text-align:center style tag doesn't do anything. Other tags, like font-weight:bold, are working. My code looks like this:

<span style="text-align:center; font-weight:bold">Welcome</span>

Any ideas what's going on here, and how to fix it? Much appreciated, thanks.

Tags (4)
0 Kudos
1 Solution

Accepted Solutions
DougBrowning
MVP Esteemed Contributor

I think 123 does mostly basic html.  Have your tried <center> ?

View solution in original post

4 Replies
DougBrowning
MVP Esteemed Contributor

I think 123 does mostly basic html.  Have your tried <center> ?

ZenMasterZeke
Frequent Contributor

No, because <center> is HTML4, and supposedly not supported in modern html. @IsmaelChivite tricks of the trade blog post from 2021 shows the updated html format. It's worth a try though.

Well shiver me timbers, it does work. Thanks @DougBrowning !

AnnaCG
by
Occasional Contributor

Thanks for the helpful post @ZenMasterZeke! I tried using the <center> tag, and while it works in Survey 123 Connect, the tag is visible in the web browser version (which is how most users will be accessing the survey). Did you run into the visible-tag-in-browser-view issue as well?

0 Kudos
AnnaCG
by
Occasional Contributor

Following up to share an html tag that worked in both Survey 123 Connect and on the web browser view:

<p style="text-align: center;">This text will be center justified!</p>