blank
blank
home
:: archives

:: categories

:: wp plugins

hosted by xg3
powered by wp
navigation by wp-dtree
bloggersg
badbehavior
© 2008, silpstream

Friday, 16th June 2006

:: WordPress-dTree v1.0 (deprecated)

Introduction

This page and version has been deprecated and new versions are released here!!!

This is a plugin created for Wordpress in order to generate javascript navigation trees for your archives. It uses the javascript engine dTree that was created by Geir Landrö.

I wrapped the wordpress APIs around it so that we can use it as a plugin. Currently it supports display of your archives based on either a yearly or a monthly tree.

There are some features of dTree that I've not quite wrapped into this plugin yet, but will be doing it over time. If you want to use those feature, go to Geir's site and read his documentation on the dTree script.

You'll find an antipixel png file included with the download. If you do find this useful, please provide a link back to this page so that others can enjoy it's benefits also.

Let me know if you have any problems or find any bugs! Thanks!

Download

The new version is here.

WP-dTree version 1.0 (zip) has been downloaded 806 times!

Installation

1. Extract the files and transfer the 'wp-dtree' folder to your plugins folder.
2. Edit the 'style.css' file found in the 'wp-dtree' folder.
3. Log into your admin panel and click on 'Activate'.
4. Goto the template file that you want the archives to show on and add in:

<?php
if (function_exists('silpstream_get_archives')) {
silpstream_get_archives('param1', 'param2');
}
?>

Where 'param1' can either be 'monthly' or 'yearly' and 'param2' tells WP-dTree to truncate titles shown in the archive after x characters. The default is 'monthly' and '16' if no parameters are defined.

Editting style.css

You should only edit the following four styles in the 'style.css' file. Changes should only be made to the 'font', 'color', 'background', and 'text-decoration' properties. I do not recommend changing the font size as the images will end up out of alignment. You can try, but don't say I didn't warn you!

dtree
This specifies the default colour, font and font size of the text displayed.

dtree a
This specifies the colour and decoration of the any links.

dtree a.node:hover, dtree a.nodeSel:hover
This specifies the colour and decoration of links on a mouseOver event.

dtree a.nodeSel
This specifies the colour and decoration of links on a mouseClick event.

Changing the Images

The images used are all stored in the 'wp-dtree/dtree-img/' directory. You can change them if you like. Just remember to keep the names the same if not you will break the script.


:: comments
Mon, 19th June 2006

Thanks! I’m testing it. So far it works very well. Great job, keep up the good work!
I have a question though.
Does it cache the query or requery each page load? Caching would be best as I will eventually have many hundreds of posts.
See it in use at my site. :-)

Also, a readme.txt file is needed in the zip for newbies. (I made my own.)


:: Don
Mon, 19th June 2006

Don,
Currently there is no cache built into this. I didn’t think that it would be useful to build that in as there is a caching plugin available, called WP-Cache2. Do a quick search for it on the plugin directories and you should find it. I may look later at some of the variable caching later on, but I’m not sure how much benefit it would bring. As for the readme, thanks for mentioning that, I’ll add it in. Cheers!


:: silpstream
Mon, 19th June 2006

I’ll check the plugin you mentioned. Do you think it’s a necessary thing to cache? Would it speed the menu once I have lots of posts? If so, I’ll use the caching plugin. What do you think?

Also, is it possible to use this with categories? Like archives but list the categories instead of the month, and then each post under each category.

What I would like to do is provide a tree for archives and another tree for categories to make navigating the site very flexible.

And lastly :-) Close the current month (or category) upon opening another?

Thanks so much!! This is very good work!


:: Don
Mon, 19th June 2006

Don,
Using cache is dependant on how much traffic you get. I certainly don’t need it… lol… Go here to find out more about it.

I had categories at first when I was using B2, but didn’t manage to get it into this version since I wanted to get my site up fast. I’ll be putting it in though, so you’ll see an update pretty soon.

As for the the closing question you had, this again is available in dTree, but I need to get some wrappers around the code for it to work here, thus another update.

Give me a bit of time and you’ll have it all! Thanks for the great comments!


:: silpstream
Mon, 19th June 2006

very nice!


:: adem
Mon, 19th June 2006

Thanks again! Awaitinig the updates :-) I’ll keep checking in.


:: Don
Wed, 21st June 2006

I have a problem with my WP-theme. The title are under the images. If you can take a look at my trying site http://millesabords.info/wp2bas/
Thanks a lot


:: MilleSabords
Wed, 21st June 2006

MilleSabords,
It looks like style.css (for WP-dTree) is not loading up. See if you can fix that, or try copying the content of the style.css file into the header area of your template. It isn’t a big file so should cause much problem.


:: silpstream
Thu, 22nd June 2006

I’ve tried to merge the dTree style in the main style.css of the template, but it doesn’t change anything. I think your (wonderful!)plugin is not compatible with the Regulus theme (http://www.binarymoon.co.uk/projects/regulus/) i use. I don’t know why. I’ve tried dTree v1 and v2, same results.


:: MilleSabords
Thu, 22nd June 2006

MilleSabords,
It took me a while but I finally figured out a fix for you. I’ve patched the file and emailed it to you. I’m not releasing it here yet because I haven’t had the chance to fully test it. It should work for the Regulus theme though. Let me know if you have anymore problems.


:: silpstream
Thu, 22nd June 2006

Thanks a lot, but i didn’t receive your email. Can you send it again or check your send


:: MilleSabords
Thu, 22nd June 2006

is difficult to assign at the menu’s item selected a personal class (style);
better if the class is assigned at the current url (if one to go at the page directly by url and not by menu) that match at the menu item;
so is better the use of menu


:: alvey
Fri, 23rd June 2006

my precedent post obviously is a question :-)

is difficult to assign at the menu’s item selected a personal class (style)?


:: alvey
Fri, 23rd June 2006

alvey,
Sorry I dodn’t realise that you were asking a question. I’m trying to understand your question, so correct me if I am wrong. Are you asking if the menu can open to the item that the page is showing if someone goes to it directly?
If so, currently it can’t be done, but I’ll see if it can be added in. Thanks!


:: silpstream
Sat, 24th June 2006

really if I copy the link of this page (where are we)
http://www.silpstream.com/blog/2006/06/16/wp-dtree-v10/
the menu is open at same page and highlight the correct item; so you have make the solution.


:: alvey
Sat, 24th June 2006

alvey,
Test it out! I think it is pretty cool! Thanks for suggesting it! I never even thought of putting something like this in.


:: silpstream
Sat, 24th June 2006

a solution for tree pages you are developing?
others: under firefox, when click on symbol or the link, remain around them
a line dotted …………


:: alvey
Sat, 24th June 2006

alvey,
I can’t do anything about the dotted lines. This seems to be how firefox deals with links when they are clicked. I’ve not tried using pages in WordPress yet, but I’ll get around to it. I am thinking of adding that in, just need to understand how Pages work first.


:: silpstream
Sat, 01st July 2006

Hmm… I just tried adding a comment and it didn’t work… using Firefox 1.5.0.4 on WinXP…

So what I was asking was, can your plugin make the sidebar titles themselves collapsable? I want to make mine as simple and clean as possible, then expand to show contents. For example, if my sidebar simply looked like this:

Noteworthy
Popular
Categories
Recent Posts
Recent Comments
Monthlies

Then, when someone clicked on Categories for example, it would look like:

Noteworthy
Popular
Categories
- cat1
- cat2
- cat3
- etc
Recent Posts
Recent Comments
Monthlies

Is that possible? Also, does your plugin support extra things like Recent Posts/Comments, Noteworthy, etc? Thx~ (and I’m copying my text this time in case it doesn’t work again ;) )


:: Dean
Wed, 05th July 2006

Dean,
Thanks for the suggestions! I’ll take a look at the other stuff and seehow I might be able to integrate it into this.


:: silpstream
Thu, 13th July 2006

wonderfull the plugin! Do I have the possibility to display the number of posts like

general (6)
specials (3)

I don’t want to show the posts in the navigation - only the categories with their number of posts.
Is it possible?
Many thanks!


:: maggy
Thu, 13th July 2006

Maggie,
I’ve not put post counts in, but I’ll definately look into it! Thanks!


:: silpstream
Fri, 14th July 2006

If you have comments to add, please add it to the new WP-dTree page. This area is now closed. Thanks for coming by!!!


:: silpstream