Skip to content
● Meet Grav Guard: keep every Grav site you run secure and up to date, all from one place. Free for up to 3 sites. Read more →

Form followed by Form

Started by Richard Hainsworth 9 years ago · 0 replies · 871 views
9 years ago

I've developed an sqlite plugin that creates a new form action 'sqlite' and takes form data and puts into a table (eg. people).
The plugin works fine. Except I want to have an intermediate step. So the user sees the form and has two buttons <continue> and <cancel>
If the user clicks on <continue>, then the form is processed again with the data being sent to the database.
I cannot figure out how to get the extra step.
I have tried putting an intermediate process, eg.

YAML
form:
  name: xx
  fields:
    -name: ff
     type: text
 buttons:
   -submit
     type: submit
  process:
    - sqlite
        table: people
    - sqliteConfirm

This works except it executes immediately, that is, the data from one step is not passed to the next process.

I've tried a couple of different ways, but can't find an approach that works.

Any suggestions?

Suggested topics

Topic Participants Replies Views Activity
Plugins · by DrPen, 1 month ago
2 478 1 month ago
Plugins · by renedebaaij, 2 months ago
1 350 1 month ago
Plugins · by Thomas, 1 month ago
1 375 1 month ago
Plugins · by complanar, 2 months ago
6 699 2 months ago
Plugins · by BenLaKnet, 2 months ago
1 642 2 months ago