• So far I placed created the plugin using the “wpmvc plugin” command and I added my database tables to the loader file and I activated my plugin. From this point, I can see the tables in my wordpress database. So far so good, this is where I get a problem. When I try to go to the screen to add I get the following error: “Fatal Error: Field “name” not found for use in a form input”. Am I missing something here? I reviewed the tutorial for the Events example. Any help would be greatly appreciated.

    http://wordpress.org/extend/plugins/wp-mvc/

Viewing 4 replies - 1 through 4 (of 4 total)
  • Does your database contain a “name” field for this table?

    You will most likely have to change the “add” and “edit” forms in views/admin !

    Thread Starter kevcpu

    (@kevcpu)

    Thanks. That solved it.

    I tried the dodmax answer but got error. I have a wp_person table and have a two columns: id , fullname. But when I set the

    <h2>Add Person</h2>
    
    <?php echo $this->form->create($model->name); ?>
    <?php echo $this->form->input('fullname'); ?>
    <?php echo $this->form->end('Add'); ?>

    ..

    my admin_people_controller:

    <?php
    
    class AdminPeopleController extends MvcAdminController {
    
    	var $default_columns = array('id', 'fullname');
    
    }

    but this is the error I’ve got.
    [MVC] Fatal Error: Field “fullname” not found for use in a form input.
    Thrown on line 4 of /home/user/www/wp-mvc/wp-content/plugins/my-plugin/app/views/admin/people/add.php

    Please help.. Thanks.

    I generated a scaffold and this is the same problem I have.

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘[Plugin: WP MVC] "Fatal Error: Field "name" not found for use in a form input"’ is closed to new replies.