Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Jignesh 31 posts 51 karma points
    Jan 18, 2012 @ 15:56
    Jignesh
    0

    dropdownlist data type selected value instead of text

    Hello,

    I am create dropdownlist data type with database datatype as integer..

    I added prevalues.. and at page select proper value..

    now in xslt i want to get value field of dropdown. It gives me text...

    Text Value

    Home 22

    Live 23

    Article 24

    i want value field that is 22 instead of Home.

    i m using this in XSLT

    <xsl:if test="$county = current()/resourceCounty"

    resourceCounty is generic properties that i created.

     

    Thanks...

  • Rodion Novoselov 694 posts 859 karma points
    Jan 18, 2012 @ 16:11
    Rodion Novoselov
    0

    Hi. You can get a full list of datatype prevalues with the library.GetPreValues() method and than to resolve the prevalue ID by its text.

  • Jignesh 31 posts 51 karma points
    Jan 19, 2012 @ 08:43
    Jignesh
    0

    Solve problem

     <xsl:variable name="topicList" select="umbraco.library:GetPreValues('1176')"/>
        <xsl:for-each select="$topicList//preValue">          
            <xsl:value-of select="current()"/>
        </xsl:for-each>

    Thanks..

  • abhijeetwaychal 5 posts 25 karma points
    Nov 29, 2012 @ 09:10
    abhijeetwaychal
    0

    Hi Guys,

    Need help in getting selected value or ID of DD, tried above code it gives all the prevalues of DD not the selected one.

    Thanks

     

     

Please Sign in or register to post replies

Write your reply to:

Draft