Copied to clipboard

Flag this post as spam?

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


  • Moran 277 posts 885 karma points
    Mar 28, 2016 @ 14:57
    Moran
    0

    Get vorto fields in a controller

    Hi I am trying to get the value of Vorto fields in a controller, is it possible? This is my code:

     public string GetStoreData(string id)
        {
            var store = uQuery.GetNode(id);
            if (store != null)
            {
    
                var storeCity = "cityName";
                return storeCity;
            }
            return string.Empty;
        }
    
  • Moran 277 posts 885 karma points
    Mar 29, 2016 @ 09:43
    Moran
    0

    Hi Anyone? I am using umbraco 7.2.6 and vorto 1.3 Thanks

  • Jeroen Oostwouder 67 posts 163 karma points
    Jul 22, 2016 @ 09:02
    Jeroen Oostwouder
    0

    Maybe too late...

    but if you include:

    @using Our.Umbraco.Vorto.Extensions
    

    at the top of your file, you can call .GetVortoValue() on any IPublishedContent object.

  • 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