Title: Export Function
Last modified: August 31, 2016

---

# Export Function

 *  Resolved [Fabbstar](https://wordpress.org/support/users/fabbstar/)
 * (@fabbstar)
 * [10 years ago](https://wordpress.org/support/topic/export-function-6/)
 * Hi Michael,
 * I hope you are well?
 * What file or files should I delete in order to remove the export function of 
   the plugin?
 * I do not want the export function of the plugin as we only use it to display 
   data, I don’t want anyone to be able to export the data – particularly not as
   this can be done by hacking the url.
 * Many thanks,
    S
 * [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)

 *  Thread Starter [Fabbstar](https://wordpress.org/support/users/fabbstar/)
 * (@fabbstar)
 * [10 years ago](https://wordpress.org/support/topic/export-function-6/#post-7234830)
 * Hi Michael,
 * Don’t worry about replying, I added a function to the theme which stops anyone
   calling a url with text “?action=cfdb-export”.
 * Thanks,
    S
 *  Plugin Author [Michael Simpson](https://wordpress.org/support/users/msimpson/)
 * (@msimpson)
 * [10 years ago](https://wordpress.org/support/topic/export-function-6/#post-7234836)
 * Interesting. If you don’t mind, please post the function.
 *  Thread Starter [Fabbstar](https://wordpress.org/support/users/fabbstar/)
 * (@fabbstar)
 * [10 years ago](https://wordpress.org/support/topic/export-function-6/#post-7234837)
 * Hi Michael,
 * No probs, I used it as part of an existing function which prevents non-admins
   going to their dashboard:
 * add_action( ‘admin_init’, ‘redirect_non_admin_users’ );
    /** * Redirect non-admin
   users to home page * * This function is attached to the ‘admin_init’ action hook.*/
   function redirect_non_admin_users() { if ( ! current_user_can( ‘manage_options’)&&‘/
   wp-admin/admin-ajax.php’ && ‘/wp-admin/admin-ajax.php?action=cfdb-export’ != 
   $_SERVER[‘PHP_SELF’] ) { wp_redirect( home_url() ); exit; } }
 *  Plugin Author [Michael Simpson](https://wordpress.org/support/users/msimpson/)
 * (@msimpson)
 * [10 years ago](https://wordpress.org/support/topic/export-function-6/#post-7234857)
 * Interesting. Thanks!

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

The topic ‘Export Function’ 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

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

 * 4 replies
 * 2 participants
 * Last reply from: [Michael Simpson](https://wordpress.org/support/users/msimpson/)
 * Last activity: [10 years ago](https://wordpress.org/support/topic/export-function-6/#post-7234857)
 * Status: resolved