Copied to clipboard

Flag this post as spam?

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


  • huw woolley 6 posts 75 karma points
    Sep 30, 2016 @ 16:44
    huw woolley
    0

    Umbraco Forms

    I am using Umbraco Forms version 4.2.1 running in Umbraco 7.4.2. The form is inserted using a Macro in to a Grid within a Razor page. I have a very simple form which should display a thank you message on submit. However, when submit is pressed, the page posts back and the data on the form disappears. No thank you message is shown. The data does get recorded in Umbraco backend though.
    How can I get the Thankyou message to show? enter image description here

    enter image description here

  • Alex Skrypnyk 6132 posts 23951 karma points MVP 7x admin c-trib
    Oct 01, 2016 @ 08:30
    Alex Skrypnyk
    0

    Hi Huw,

    Did you change code of views?

    Can you share code?

    Thanks,

    Alex

  • huw woolley 6 posts 75 karma points
    Oct 01, 2016 @ 09:54
    huw woolley
    0

    Which views do you mean please? Views relating to Umbraco Forms have not been changed at all. The views in which they sit (within Grids) have been extensively changed. Are the Umbraco Form Views actually available? Where are they?
    Really struggling to debug this problem. Any assistance much appreciated!

    Thanks.

  • huw woolley 6 posts 75 karma points
    Oct 01, 2016 @ 11:39
    huw woolley
    0

    I've found the solution to this though don't understand it!

    If I render the grid like this:

    @Html.GetGridHtml(Model.Content, "grid")

    it works.

    If I render the grid like this:

    @Model.Content.GetGridHtml("grid")

    It doesn't.

    When looking at the HTML that is rendered, the hidden field "RecordState" within the Umbraco Forms Form is not populated with @Model.Content.GetGridHtml("grid") but is when @Html.GetGridHtml(Model.Content, "grid") is called.

    Any ideas why this may be?

Please Sign in or register to post replies

Write your reply to:

Draft