Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Getting data values from form in Fat-Free framework

I'm migrating from codeigniter to Fat-Free (F3) and trying to get my head around the quirks.

Regarding the following form:

<form ACTION = "<?php echo $_SERVER['PHP_SELF'];?>" METHOD="POST">
  <input type="text" name="theirName" value="" required="required">
    ...

In standard PHP I get the POST value like this:

$name = $_POST['theirName'];

Or in codeignitor:

echo form_open('someclass/some_method_of_someclass');
$name = $this->input->post('name');

How do I get data from a form in a view in f3/fatfree?

like image 348
user2984700 Avatar asked May 10 '14 19:05

user2984700


1 Answers

You can get it from the Hive:

$name = $f3->get('POST.name');
like image 168
Nilam Sari Avatar answered Nov 15 '22 10:11

Nilam Sari