Title: Force development mode
Last modified: July 26, 2017

---

# Force development mode

 *  [tproli](https://wordpress.org/support/users/tproli/)
 * (@tproli)
 * [8 years, 10 months ago](https://wordpress.org/support/topic/force-development-mode/)
 * Thanks for the plugin, I use Tracy in various projects and I’m sure it will be
   handy in WP too.
 * I have an issue that the debugger is not initializing because I’m developing 
   on a dev server and not on localhost. I’ve managed to force development mode 
   using this in “/wp-tracy/vendor/ktstudio/wp-tracy/src/index.php”:
 *     ```
       if(defined("WP_TRACY_FORCE_DEVELOPMENT_MODE") && WP_TRACY_FORCE_DEVELOPMENT_MODE === true) {
       	Tracy\Debugger::enable(Tracy\Debugger::DEVELOPMENT);
       } else {
       	Tracy\Debugger::enable(defined("WP_TRACY_ENABLE_MODE") ? WP_TRACY_ENABLE_MODE : null); // hooray, enabling debugging using Tracy
       }
       ```
   
 * Now in functions.php you can define a WP_TRACY_FORCE_DEVELOPMENT_MODE constant
   to true to get the debugger. Of course you should wrap this in a condition to
   enable Tracy only when you need it.
 *     ```
       $user = wp_get_current_user();
       if($user->user_email === 'admin@admin.com') {
       	define('WP_TRACY_FORCE_DEVELOPMENT_MODE', true);
       }
       ```
   
    -  This topic was modified 8 years, 10 months ago by [tproli](https://wordpress.org/support/users/tproli/).
    -  This topic was modified 8 years, 10 months ago by [tproli](https://wordpress.org/support/users/tproli/).
    -  This topic was modified 8 years, 10 months ago by [tproli](https://wordpress.org/support/users/tproli/).

The topic ‘Force development mode’ is closed to new replies.

 * ![](https://ps.w.org/wp-tracy/assets/icon-256x256.png?rev=1943241)
 * [WP Tracy](https://wordpress.org/plugins/wp-tracy/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/wp-tracy/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/wp-tracy/)
 * [Active Topics](https://wordpress.org/support/plugin/wp-tracy/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/wp-tracy/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/wp-tracy/reviews/)

 * 0 replies
 * 1 participant
 * Last reply from: [tproli](https://wordpress.org/support/users/tproli/)
 * Last activity: [8 years, 10 months ago](https://wordpress.org/support/topic/force-development-mode/)
 * Status: not resolved