Form submission data not reaching PHP script using custom Driver file #1197
-
Hi Valet community, I'm encountering what seems to be a very bizarre issue related to POST data from a form submission being cleared after the request passes through our custom Driver. The backgroundI have a bespoke PHP CMS project that we've adopted from a client. This CMS uses Apache URL rewrites to handle routing. As Valet uses Nginx under the hood instead of Apache, the rules present in the What I've done so farIn order to recreate the URL rewriting effect in Valet, I've created the following custom Driver:
The issue I'm experiencingYou'll notice in my
This works successfully & routes the form submission through to the intended PHP script. However, I'm finding that the form data (accessed via When running the following inside the
We get the following output (values of keys changed to 'xxx' for security purposes):
However running this in the PHP script & resubmitting the form (to ensure the request doesn't change to a
Other things I can confirm:
|
Beta Was this translation helpful? Give feedback.
Replies: 2 comments
-
Bump... Any chance anybody has experienced something similar with this & may be able to help? 🙏 |
Beta Was this translation helpful? Give feedback.
-
So it turns out my sleep deprivation after recently having a child was the culprit on this occasion. 🙄🤦♂️ The issue had nothing to do with Valet & it was in fact at the application layer where the $_POST data was being emptied. 😑 There's at least 2 days of my life I'm not getting back! 😩 |
Beta Was this translation helpful? Give feedback.
So it turns out my sleep deprivation after recently having a child was the culprit on this occasion. 🙄🤦♂️ The issue had nothing to do with Valet & it was in fact at the application layer where the $_POST data was being emptied. 😑
There's at least 2 days of my life I'm not getting back! 😩