Title: [Plugin: WP-dTree] Collpase all default
Last modified: August 19, 2016

---

# [Plugin: WP-dTree] Collpase all default

 *  [wbdsn](https://wordpress.org/support/users/wbdsn/)
 * (@wbdsn)
 * [15 years, 6 months ago](https://wordpress.org/support/topic/plugin-wp-dtree-collpase-all-default/)
 * Hi
 * Is it possible to have the WP-dTree collapse all as default?
 * If you go to a sub page, close the browser, then go to the homepage again the
   tree opens to the sub-page.
 * I’ve gone through the forums twice and can’t find this.
 * Great plugin!
 * Thanks

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

 *  Plugin Author [ulfben](https://wordpress.org/support/users/ulfben/)
 * (@ulfben)
 * [15 years, 6 months ago](https://wordpress.org/support/topic/plugin-wp-dtree-collpase-all-default/#post-1757100)
 * disable `open to selection` in the widget.
 *  Thread Starter [wbdsn](https://wordpress.org/support/users/wbdsn/)
 * (@wbdsn)
 * [15 years, 6 months ago](https://wordpress.org/support/topic/plugin-wp-dtree-collpase-all-default/#post-1757108)
 * Thanks for the reply. I tried that and it didn’t work.
 * I’ve just done a new installation of wordpress and the plugin and it’s still 
   leaving the tree open.
 * Help is greatly appreciated!
 *  Plugin Author [ulfben](https://wordpress.org/support/users/ulfben/)
 * (@ulfben)
 * [15 years, 6 months ago](https://wordpress.org/support/topic/plugin-wp-dtree-collpase-all-default/#post-1757141)
 * Actually, I notice I gave you the wrong advice. _Enable_ Open To Selection and
   it will close the entire tree when visiting the main page. That’s default behaviour
   and works on all of my installations.
 * WP-dTree compares the requested URL with the node URLs and opens the matching
   one (if any). The way this is implemented (matching against the generated javascript
   source) might cause false positives, but this is directly noticable in the page
   source – WP-dTree prints out what was requested, and which match and node it 
   selected for the request. If there was no match it’ll just close the tree.
 * Thus: the only reason the tree would stay open would be if your main page has
   the same (or similar) request URL as some other content. Check your sources.

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

The topic ‘[Plugin: WP-dTree] Collpase all default’ is closed to new replies.

 * ![](https://s.w.org/plugins/geopattern-icon/wp-dtree-30_fcfcf8.svg)
 * [WP-dTree](https://wordpress.org/plugins/wp-dtree-30/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/wp-dtree-30/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/wp-dtree-30/)
 * [Active Topics](https://wordpress.org/support/plugin/wp-dtree-30/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/wp-dtree-30/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/wp-dtree-30/reviews/)

## Tags

 * [WP-dTree 3.0](https://wordpress.org/support/topic-tag/wp-dtree-3-0/)

 * 3 replies
 * 2 participants
 * Last reply from: [ulfben](https://wordpress.org/support/users/ulfben/)
 * Last activity: [15 years, 6 months ago](https://wordpress.org/support/topic/plugin-wp-dtree-collpase-all-default/#post-1757141)
 * Status: not resolved