Copied to clipboard

Flag this post as spam?

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


  • Shahid Hafiz 7 posts 27 karma points
    Feb 04, 2015 @ 16:08
    Shahid Hafiz
    0

    Accessing the grid layout content programmatically

    Hi, I am using a grid layout datatype (from the default fano template). As the structure of the page is now determined by the editor, how do I as a programmer retrieve specific parts of the page content programmatically. Eg. My client has a news page with multiple rich text editors in the grid. I need to extract the leader text and display it on a summary page elsewhere.

    Any help much appreciated.

  • Dennis Aaen 4457 posts 17970 karma points admin hq c-trib
    Feb 04, 2015 @ 20:16
    Dennis Aaen
    1

    Hi Shahid,

    At the moment it is not possible for you to take a chunk of the content from a grid editor. The grid is also the first draft of it since it was introduced in Umbraco 7.2. I have no information if this will be possible in a later versions of Umbraco.

    But if you see the best practices for the grid layout there is a section about limitations for the grid layout. http://our.umbraco.org/Documentation/Using-Umbraco/Backoffice-Overview/Property-Editors/Built-in-Property-Editors-v7/Grid-Layout-Best-Practices

    In the section you can see one of the limitations is that - There is no managed api to drill into the grid content and target specific cell content - so a grid layout is not a recommended storage of reusable content.

    /Dennis

  • 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