Skip to content

Regression: Forms inside RTE-rendered Blocks do not re-render after POST in Umbraco 17 RC2 (works in RC1) #20867

@kkarsin6

Description

@kkarsin6

Which Umbraco version are you using?

17 RC2

Bug summary

When a form is placed inside a Block (single block, not Block Grid) that is rendered inside an RTE, submitting the form in RC2 causes the block to render stale output.
The Razor view inside the block does not re-execute.

This results in:

@DateTime.Now not updating

ViewData values from the POST not appearing

The block output being reused from cache

This behavior worked correctly in RC1.

Specifics

No response

Steps to reproduce

Steps to Reproduce

  1. Add a single block to an RTE.
  2. In that block, render a form using a SurfaceController:

View inside block:

@model TestSearchViewModel

@using (Html.BeginUmbracoForm<ProductFinderFromController>(nameof(ProductFinderFromController.Submit)))
{
    <text>first load at: @DateTime.Now</text>
    <button type="submit">Hit me!</button>
}

@if (ViewData["CurrentTime"] is string t)
{
    <div>Submitted at: @t</div>
}

Controller:

[HttpPost]
public IActionResult Submit(TestSearchViewModel model)
{
    ViewData["CurrentTime"] = DateTime.Now.ToString("HH:mm:ss");
    return CurrentUmbracoPage();
}
  1. Load the page → time renders correctly.

  2. Click the button → POST executes.

  3. Page re-renders, but the block output is frozen.

Expected result / actual result

Expected Behavior

  • The Razor block should re-render after the POST.

  • @DateTime.Now should show a new timestamp.

  • ViewData["CurrentTime"] should show the submitted time.

  • Block output should not be cached across form submissions.

Actual Behavior (RC2)

  • The block inside the RTE does not re-render.

  • @DateTime.Now remains the original value.

  • ViewData["CurrentTime"] never appears or updates.

The block appears frozen or cached.

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions