Copied to clipboard

Flag this post as spam?

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


  • Paul Griffiths 358 posts 998 karma points
    May 21, 2014 @ 10:32
    Paul Griffiths
    0

    User Control:Cascading Dropdown list

    Hi everyone

    Looking if someone could possible point me in the right direction here please. I am wanting to build a cascading dropdownlist user control using c# and was wondering how the best way would be to target the specific nodes in my content tree in umbraco.

    For example if i had the following structure in my content section

    Merseyside   (type = county)
            Liverpool (type = city/town)
                 Area of Liverpool 1 (type = suburb)
                 Area of Liverpool 2 (type = suburb)
                 Area of Liverpool 3 (type = suburb)
            Birkenhead (type = city/town)
                 Area of Birkenhead 1 (type = suburb)
                 Area of Birkenhead 2 (type = suburb)
    etc......
    

    from the front end i am wanting to populate the first drop-down list with the city/towns (e.g Liverpool, Birkenhead) and based on the value that is selected by the user i want to automatically populate the second dropdownlist with the related child suburbs.

    How can I make the link between my user control and the umbraco content tree so I can target these nodes?

    would it be something to do with adding the following libraries and using XPATHNodeIterator

    using System.Xml.XPath;
    using umbraco.NodeFactory;
    using umbraco.cms.businesslogic.web;
    using umbraco.businesslogic;
    

    Any help or advice would be greatly appreciated as I have tried using XSLT but unfortunately failed (http://our.umbraco.org/forum/developers/xslt/52622-Dependent-dropdown-list)

    Thanks all

    Paul

  • Paul Griffiths 358 posts 998 karma points
    Jun 05, 2014 @ 11:33
    Paul Griffiths
    0

    Hello peeps! still struggling if anyone could please help?

    Does anyone know how I can target the content nodes from a user control?

    Ill take anything :)

    Thanks

    Paul

  • This forum is in read-only mode while we transition to the new forum.

    You can continue this topic on the new forum by tapping the "Continue discussion" link below.

Please Sign in or register to post replies