Welcome Guest, Not a member yet? Register   Sign In
Cannot access request values from controller
#1

Hello guys, I stuck with accessing my request.
Here's from:
<form action="http://****/ajax/" method="POST">
    <label for="fname">First name:</label><br>
    <input type="text" id="fname" name="fname"><br>
    <label for="lname">Last name:</label><br>
    <input type="text" id="lname" name="lname">
    <input id="send" type="submit" value="send">
</form>


Controller method:
    public function ajaxTest()
    {
        $fname = $this->request->getVar('fname');
        print($fname);
    }
Reply


Messages In This Thread
Cannot access request values from controller - by dziadek - 01-06-2023, 01:44 AM



Theme © iAndrew 2016 - Forum software by © MyBB