Using Literal control instead of TextField in Profile Templa

Posted by Community Admin on 03-Aug-2018 18:53

Using Literal control instead of TextField in Profile Template

All Replies

Posted by Community Admin on 01-Sep-2011 00:00
Hi,

I am trying to create a custom profile template for my application, and have editted the template, first i was using the TextField control but it just outputs loads of divs which i have no idea why anyone would ever need, so i want to output just the first name and last name (no labels) and i get this mess (not even sure it would validate)

<h3><div id="Column1Content_C003_userProfilesFrontendDetailsRead_ctl00_ctl00_firstName" class="sfprofileFirstName">
<div id="Column1Content_C003_userProfilesFrontendDetailsRead_ctl00_ctl00_firstName_ctl00_ctl00_textLabel_read" class="sfTxtContent">Roberto</div>
<div id="Column1Content_C003_userProfilesFrontendDetailsRead_ctl00_ctl00_firstName_ctl00_ConditionalTemplates" style="display:none;">
</div>
<div id="Column1Content_C003_userProfilesFrontendDetailsRead_ctl00_ctl00_lastName" class="sfprofileFirstName"></h3>

When all i want is this

<h3>Roberto Modica</h3>

I tried to use literals instead but i guess this profile is not databound Eval will not work so i am now stumped at what started out to be something simple has taken ages.

Does anyone know how can i use literals in the profile template, or atleast remove all the crap that the TextField spurts out.

Thanks,

Rob
Posted by Community Admin on 02-Sep-2011 00:00
Think i have found it,  i think i can use:

SitefinityLabel

if that helps anyone else
This thread is closed