Skip to content

Add support for form submits #683

Draft
Toflar wants to merge 2 commits intoPHP-CMSIG:0.12from
Toflar:feature/serializable-search-builder-html-form-support
Draft

Add support for form submits #683
Toflar wants to merge 2 commits intoPHP-CMSIG:0.12from
Toflar:feature/serializable-search-builder-html-form-support

Conversation

@Toflar
Copy link
Copy Markdown
Member

@Toflar Toflar commented Apr 28, 2026

This is an idea I came up with built on top of #682.

I'm introducing a FormSearchInputNormalizer to bridge regular HTML form submissions ($_POST) with ArraySearchBuilderFactory::build() in a safe, typed way.

Why is this useful?
While building with Loupe, I noticed that as a dev, I would like to give the full flexibility to the designers without building a huge controller and thinking about all the use cases that could possibly exist. With this PR, we'd have a strong separation-of-concerns improvement:

  • backend devs can ship a very small, explicit controller
  • designers/front-end teams can fully control form structure, UX and search behavior

Wdyt?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant