Modernized HTML Coding not Working... sort of

556
3
03-10-2022 10:43 AM
DanBihari
New Contributor III

@IsmaelChivite

I found out recently that the webforms no longer recognize my HTML coding and that it has been updated or "modernized" to use <div style...> tags.  I was surprised by this since this was not on my radar as a thing I had to worry about.  I tried to follow the Tricks and Trade Blog article on this topic and had varying success.

Survey123 Tricks of the Trade: Quick guide to modernize HTML formatting tags in your survey (esri.co...

One of the biggest issues that I have run into is that the HTML formatting, which was outlined in the blog post, seems to work and displays what I expect in Survey123 Connect but when I view my published survey in the webform, it's a different story and does not give me what I want or what I see in Survey123 Connect.

For example,

I tried to make the first word in a text string (this is a note question) 

<div style="font-weight:bold">Note:</div> Assess 10 plants (3 plants in 3 areas plus 1 additional plant in one of these 3 areas; Distance these 3 areas equally apart, relative to the size of field/plot; a minimum of 20 m apart). Avoid assessing plants within 10 m of fields’ edge.

Survey123 Connect

DanBihari_0-1646936517749.png

Webform

DanBihari_1-1646936547579.png

Now I will be the first to admit that I am new to <div> tags so I may be doing this completely wrong but if I am why does it give me what I want in Connect but not the webform  Also, why is the exact same code adding in a <br> for no reason?

Another issue that I ran into is group labels also do not recognize the new HTML formatting in the webform.

begin groupContactInfo<div style="text-align: center">Caller Contact Information</div>

 

Survey123 Connect

DanBihari_2-1646936878306.png

Webform

DanBihari_3-1646936997750.png

 

Once again, the webform does not recognize this new "modernized" formatting.

Is this on Esri's radar and will this be fixed at some point?  It's incredible difficult to develop and publish and survey using one piece of software (Connect), which gives you no errors and the appearance that you want, to only have it look completely different in the webform.

Any help or guidance would be greatly appreciated. 

And I completely agree with @Amanda__Huber . it would be VERY helpful if someone could develop a ArcGIS Blog article about this for awareness and how to use this new formatting.  It would also be very handy to have it as a sample template in Connect.  There is one already in there that references the old formatting but not the new.

Thank you for your help.

~Dan

 

3 Replies
Amanda__Huber
MVP Regular Contributor

We are also seeing issues with this new "Modernized" HTML in our S123Connect published forms that are viewed as Web Forms. 

We've had to just completely remove all HTML formatting completely because of it not working. This is not ideal.

DanBihari
New Contributor III

@IsmaelChivite

Unfortunately I have come up with yet another example of how the new HTML formatting is just not working.

This example occurs in a choice list.  Included below is an example of the old way of HTML formatting vs. the new HTML formatting.

list_namenamelabel
CRW_BT_TraitsCry3Bb1<b>Cry3Bb1</b> (includes VT TriplePRO, VT3P RIB Complete, Yieldgard Rootworm or Yieldgard VT Triple)
CRW_BT_TraitsCry34_35Ab1<div style="font-weight:bold">Cry34/35Ab1</div> (includes AcreMax CRW, AcreMax1, AcreMax Xtra, Herculex RW, Herculex Xtra, or Intrasect Xtra)
CRW_BT_TraitsCry3Bb1+Cry34_35Ab1<div style="font-weight:bold">Cry3Bb1+ Cry34/35Ab1</div> (includes SmartStax, STX Refuge Advanced, SmartStax RIB Complete, or SmartStax Enlist)

 

You can see the difference right away as to what HTML formatting is working and which is not.

Survey123 Connect

DanBihari_0-1647371745054.png

What makes this issue interesting is for some reason it actually works in the webform... sort of.  It still adds a phantom <br> for no apparent reason.  This is also still very much an issue.

Also, the webform actually respects both versions  of HTML formatting.  So you can use the old HTML formatting in some parts of the Survey123 webfrom but not others?

Where is the consistency here?  I'm even more confused now than I was before.

Webform

DanBihari_1-1647372090385.png

As always, I would really appreciate it if someone could clarify what I am seeing and potentially help me solve this.

Thank you for any and all assistance.

~Dan

 

 

Strahanjen
Occasional Contributor II

I'm also looking for guidance on this topic!