When the form is submitted it will load ok if I comment out $autoin = $_POST[autoin] and $colnum = $_POST[cnumin] The count returned is = to 4. This is the form:
<form class="" action="https://mypage" method="POST"> CVS File to upload: <input id="cvsfi" name ="cvsfi" type = file required/> Check the box if auto increment: <input id="autoin" name ="autoin" type = checkbox> Column number for key: <input id="cnumi" name="cnumi" size="2" type="number" required/> <input name="submit" type="submit" value="Submit"></form>
This is the page:
` <?php
/**
* Template Name: Template uploadcsv
*
* @package Longevity
*
*
*/
get_header(); ?>
<div class="container">
<?php
//error_reporting(E_ALL);
//ini_set('display_errors',1);
if( isset($_POST['action']) != 0)
{
echo "No form submitted";
goto GetOut1;
}
echo count($_POST);
GoTo GetOut1;
$csvin = $_POST['cvsfi'];
$autoin = $_POST[autoin];
$colnum = $_POST[cnumin];
GetOut1:
?>
</div>
<?php get_footer(); ?>`
I tried $_POST and $_GET. The page hangs on both.
Larry Dayhoff is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.