Wordpress Themes - WP Forum at BFA

Wordpress Themes - WP Forum at BFA (http://forum.bytesforall.com/index.php)
-   Plugins & Atahualpa (http://forum.bytesforall.com/forumdisplay.php?f=16)
-   -   Hackdalic's Table Of Contents Box Plugin -- is a Yes! (http://forum.bytesforall.com/showthread.php?t=2214)

fromtheranks Jun 29, 2009 02:43 AM

Hackdalic's Table Of Contents Box Plugin -- is a Yes!
 
My site will have quite a few long technical articles (in MS Word, with images, they are 20 - 30 or more pages long and that is after breaking them up into logical sub-subjects)

Even paired down these are too long, in my opinion, to have my readers scanning downward and downward and ...

Part of the solution was to use the <!--nextpage--> tag ... judiciously.

The other part was to find a good working TOC that I could add to each post so the reader could jump to any header in the doc desired.

After a fair amount of research and experimenting, I chose Hackadelic's.

I did so, in part, because after installing it, it both worked was very presentable out of the box and was customizable.

The other reason was because I can pair it up with the nextpage tag (the toc tag can go after it) so that you have a TOC on each page of a multi-page Post. This was critical. The reader can be on page 4, click on a heading link in the TOC and be back on Page 2 instantly. :)

I won't go into all the details here, you can read them for yourself. However, a few tips are in order as some of the install and usage instructions were a little unclear.

In the Plugin Management Page:
  1. Shortcode Parameter Defaults --> "The Default CSS class ...": you can set either "toc-right" or "toc-left" as a parameter. Don't add any class=, quotes, boxes, or anything else. There's no reason to set toc, that is the default.
  2. Shortcode Parameter Defaults --> "The default inline CSS Style ...": currently this only takes a max-width:XXpx or max-width:xx% property. I chatted with Hackadelic about this via e-mail and there's a glitch somewhere -- it should take an entire string of CSS styles. He's looking into it. However, it is not really an issue as the styling can all be done via the CSS Insert. ... Speaking of which:
CSS Insert:

On his site you will find a CSS Template file with default, workable, style settings. This must be downloaded and inserted into ATO --> HTML/CSS Inserts --> CSS Inserts. You drop it in, it works as is, then tweak to taste. By the way, Flynn assured me there is plenty of room for it as the CSS Inserts are stored in the database.

Aside from changing the colors to match my theme colors, I added a couple of mods to his CSS template that you may or may not have use for:

1. I added hover logic for the unordered list in the body of the TOC:

Code:

/* added hover logic */
div.toc li a:hover {
    color:#000099;
    text-decoration: underline;
}

2. I added a fifth level to the list as, yes, some of my posts go down that far and Hackadelic only has four defined:

Code:

/* added fifth level */
div.toc li.toc-level-5 {
    padding-left: 1.0em;
}

Hope this helps.

juggledad Jun 29, 2009 04:48 AM

Nice write-up!

fromtheranks Jun 29, 2009 04:49 PM

Thank you, Juggledad.

I figure with all the help I've gotten on this forum, it is only fair to give some back.

:)


All times are GMT -6. The time now is 01:05 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.