I am new in WordPress plugin development.
This is my core PHP and HTML code
create-table.html
<form method="post" action="function.php">
<input type="text" name="table_name">
<input type="submit" name="create">
</form>
function.php
if(isset($_POST['create'])
{
$table-name=$_POST['table_name'];
//create table query
header("location: add_table_attribute.php");
}
I want to use this same process in my WordPress plugin development. Please any one help me.
Thanks in advance.
Creating Tables with plugin This page shows how to work with tables in plugins. Example on that page includes table creation during installation of plugin. But it can be dynamically used also to create table. See below.
Note : don’t use – in variable names.