I have three attributes, ${school_url}, and ${school_lat} and ${school_lon}. The current text is included in a 'hint' attribute in Connect:
<br>Website: <a href="${school_url}">${school_url}</a></font><br>Map: <a href="https://www.google.com/maps/place/@${school_lat},${school_lon},17z">Google</a>
Website: ${school_url}
Map: Google
The mobile version displays properly and hyperlinks work great. However, in the web version I get the following:
I'm not sure what to add/remove to correct the display, removing the unnecessary items in the hyperlinks (for the the web version).
Solved! Go to Solution.
Here's the fix... and the '<br>' tags are working in Edge.
Hi Todd,
I would recommend that you use the Concat() function in the calculation field as the Survey123 webform can be problematic is these cases.
Once I inserted your HTML script into the calculation field, I was able to display the hyperlink correctly in both the Field app and the webform.
concat('<a href="',${school_url},'">',${school_url},'</a>') concat('<a href=','"https://www.google.com/maps/place/@',${school_lat},${school_lon},',17z">Google</a>') |
Hope this helps.
Regards
Alber
@Alber_Verster worked kinda. You need an extra ',' included in the map url between the lat/lon.
concat('<a href=','"https://www.google.com/maps/place/@',${school_lat},',',${school_lon},',17z">Google</a>')
The only issue I still have is embedding the new concat-ed variables in my 'hint' attribute. Once I add them back it jacks it up.
I have several variables I'm adding as you can see and by using the <br> tags it cleans up the display (versus one variable as shown above). I notice the extra space before the address string. Maybe I need to do a concat on the entire html string?
I'm testing using Edge and not sure how to have the html breaks <br> removed. Here is an example:
concat(${school_address_street},' ',${school_address_city},', ',${school_address_state}, '<br>',${school_address_county},' County')
Here is the result:
Hmmmmm....
Here's the fix... and the '<br>' tags are working in Edge.