Is the "name" attribute different? That's what ends up in the $_POST.
As for the general problem, I think you could put the fields of the first form in the second form as hidden fields and set their values with a preHook in the second page. That way, all fields will end up in the $_POST array when the second page is submitted.
Assuming that the first page is posting to the second page, I would do it with a custom snippet at the top of the second page. Something like this:
$firstFormFields = array(
"name1",
"someotherfield",
"yetanotherfield",
}
foreach($firstFormFields as $field) {
if (array_key_exists($_POST, $field)) {
$modx->setPlaceholder($field, $_POST[$field]);
}
}
return '';
Thx BobRay.
The forms are not following eachother. Just think of it as some kind of very simple shoppingcart.
The customer fills in one form, goes to some other pages and then fills in second form (or third, or fourth, ...) en everything should come together if they go to the resultpage.
Even better should be if name1, name2, name3, etc... could have the same name and put together in an array. In that way it's more dynamic.
Hope you understand what I mean.
I'm glad you got it sorted.