Problem with isset and $_POST
After the second form </form> make a small change close the first two if’s, and remove the two } from end of function </form><?php } } if(isset($_POST[‘zapisz’])) { $woda_ciepla_kuchnia=1; $data_odczytu = ‘0013-00-00 22:00:00’; $data = array( ‘id’ => ”, ‘adres’ => ‘dasd’, ‘data_odczytu’ => $data_odczytu, ‘woda_ciepla_kuchnia’ => 1, ); $wpdb->insert(wp_ow_odczyty, (array)$data); } }