Edit Record from List view
-
First of all thank you for a wonderful plugin. I must apologize for reaching out to you but I have gone through all the documentation and support forums trying to allow someone to edit a record from the [pdb-list] page. Right now I have a link showing up that is clickable but it takes you to the [pdb_single] page which is not editable. So far I have done the following:
1) Copied “pdb-list-default.php” into “wp-content/themes/lifestyle/templates” and added the following:
<tbody> <?php while ( $this->have_records() ) : $this->the_record(); // each record is one row ?> <?php $field = new PDb_Template($this); ?> <tr> <?php while( $this->have_fields() ) : $this->the_field(); // each field is one cell ?> <td class="<?php echo $this->field->name ?>-field"> <?php /* * put the edit link URL into the link property of the field */ if ($this->field->name == 'edit_link') { $this->field->link = $record->get_edit_link(); } $this->field->print_value(); ?> </td> <?php endwhile; // each field ?> </tr> <?php endwhile; // each record ?> </tbody>
2) I’ve added “edit_link” in the Manage Database Fields with the following properties:
– Name: edit_link
– Title: Edit User
– Default: EDIT
– Form Element: Text-line
– Read-only3) Made sure Single Record Page points to the page with [pdb_single].
I’m at a loss. I’ve tried this site but it appears to be down. Any help would be greatly appreciated! Thank you!
- The topic ‘Edit Record from List view’ is closed to new replies.