Title: Editing via shortcode variable?
Last modified: August 22, 2016

---

# Editing via shortcode variable?

 *  Resolved [jsa922](https://wordpress.org/support/users/jsa922/)
 * (@jsa922)
 * [11 years, 4 months ago](https://wordpress.org/support/topic/editing-via-shortcode-variable/)
 * Is it possible to allow the toggling of edit functions by making the `edit="true"`
   a variable? I have a user-editable table on one page that doesn’t always need
   to be edited, but will always be used to select values to paste elsewhere. I 
   tried adding a selection box to my search form, and a POST reference to the shortcode,
   but it doesn’t work. Here is what I tried:
 *     ```
       <form name="test" action="" method="POST">
       ...[other elements]...
       <select name="edstatus">
       <option value="true">Enabled</option>
       <option value="false">Disabled</option>
       </select>...[other elements]...</form>
       [cfdb-datatable...{filter and atts}
       ...edit=&_POST(edstatus)]
       ```
   
 * This code is treated as if `edit="false"` regardless of what the value of the
   selection element is. I didn’t know if I had the syntax wrong, or if what I was
   trying to do was just not possible.
 * Thanks!
 * [https://wordpress.org/plugins/contact-form-7-to-database-extension/](https://wordpress.org/plugins/contact-form-7-to-database-extension/)

Viewing 4 replies - 1 through 4 (of 4 total)

 *  Plugin Author [Michael Simpson](https://wordpress.org/support/users/msimpson/)
 * (@msimpson)
 * [11 years, 4 months ago](https://wordpress.org/support/topic/editing-via-shortcode-variable/#post-5715185)
 * Try it with
 * `edit="$_POST(edstatus)"`
 *  Thread Starter [jsa922](https://wordpress.org/support/users/jsa922/)
 * (@jsa922)
 * [11 years, 4 months ago](https://wordpress.org/support/topic/editing-via-shortcode-variable/#post-5715233)
 * I tried `edit="$_POST(edstatus)" but it still behaves as if it were`edit=”false”`.
   Any other thoughts?
 *  Plugin Author [Michael Simpson](https://wordpress.org/support/users/msimpson/)
 * (@msimpson)
 * [11 years, 4 months ago](https://wordpress.org/support/topic/editing-via-shortcode-variable/#post-5715277)
 * That’s not working. I’ll push version 2.8.27 shortly with a fix.
 *  Thread Starter [jsa922](https://wordpress.org/support/users/jsa922/)
 * (@jsa922)
 * [11 years, 4 months ago](https://wordpress.org/support/topic/editing-via-shortcode-variable/#post-5715286)
 * The fix works! This is great; now my partners can turn off editing when browser
   behavior gets in the way of copy/paste for client issues. THANKS! Marking this
   matter “Resolved.”

Viewing 4 replies - 1 through 4 (of 4 total)

The topic ‘Editing via shortcode variable?’ is closed to new replies.

 * ![](https://s.w.org/plugins/geopattern-icon/contact-form-7-to-database-extension_ffffff.
   svg)
 * [Contact Form DB](https://wordpress.org/plugins/contact-form-7-to-database-extension/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/contact-form-7-to-database-extension/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/contact-form-7-to-database-extension/)
 * [Active Topics](https://wordpress.org/support/plugin/contact-form-7-to-database-extension/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/contact-form-7-to-database-extension/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/contact-form-7-to-database-extension/reviews/)

## Tags

 * [edit](https://wordpress.org/support/topic-tag/edit/)

 * 4 replies
 * 2 participants
 * Last reply from: [jsa922](https://wordpress.org/support/users/jsa922/)
 * Last activity: [11 years, 4 months ago](https://wordpress.org/support/topic/editing-via-shortcode-variable/#post-5715286)
 * Status: resolved