More in this section

Forums / General Discussions / Using Literal control instead of TextField in Profile Template

Using Literal control instead of TextField in Profile Template

2 posts, 0 answered
  1. Roberto
    Roberto avatar
    146 posts
    Registered:
    08 Feb 2008
    01 Sep 2011
    Link to this post
    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
  2. Roberto
    Roberto avatar
    146 posts
    Registered:
    08 Feb 2008
    02 Sep 2011
    Link to this post
    Think i have found it,  i think i can use:

    SitefinityLabel

    if that helps anyone else
2 posts, 0 answered