Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
SA Toc / Anchors Plugin
#11
ren! Wrote:Hi Shawn,
I like your TOC PlugIn and wonder if there is a way to tweak it to:
- create a template tag and /or
- add an ID or Class to the top- <ul></ul> Element

With more and more Wiki pages it becomes a pain in the,.. fingers,... to allways add a ID or wrapper for CSS-styling
A template tag like: "get_TOC_anchor('PARAM=ID');" or sth. like that would be killer. as i'd loved to place the TOC somewhere near - and not within the content - without having to bother with css-positioning conflicts.

thx Ren

I had a way to do this, let me see if I left it in after I rewrote some stuff.
I had this planned for next version, ability to call it for any slug, and call with no menu.

The problem, is that this plugin does 2 things.

1. It is a content filter, adds ids to all headings without them, so you can link to them, but only does so for pages with a menu. This is for optimization of course, we don't want to have to do this more than once or when its not needed.

2. It creates the menu based on the headings.

So the problem is, if you want to create a menu by function, it has to happen after the content filter runs or you can simply not use that feature of it. If calling by function, I could maybe set a global and do the filter manually, it will occur twice, but cant think of another way at the moment.

I can also add a wrapper or a class to the ul I guess, I don't typically like to do that with plugins, maybe I can make it a user parameter.

Ideas welcome.
NEW: SA Admin Toolbar Plugin | View All My Plugins
- Shawn A aka Tablatronix
Reply


Messages In This Thread
SA Toc / Anchors Plugin - by shawn_a - 2012-02-24, 12:49:22
RE: SA Toc / Anchors Plugin - by shawn_a - 2012-12-08, 18:38:08
RE: SA Toc / Anchors Plugin - by jeremiah.holder - 2012-12-28, 11:19:03
RE: SA Toc / Anchors Plugin - by vanfruniken - 2017-05-30, 20:24:51
RE: SA Toc / Anchors Plugin - by shawn_a - 2017-05-30, 23:00:36
RE: SA Toc / Anchors Plugin - by shawn_a - 2017-05-31, 00:50:01
RE: SA Toc / Anchors Plugin - by lupon - 2019-05-25, 02:19:13
RE: SA Toc / Anchors Plugin - by Oleg06 - 2023-01-20, 10:15:11
RE: SA Toc / Anchors Plugin - by Oleg06 - 2023-01-20, 21:11:50
RE: SA Toc / Anchors Plugin - by Hypertexter - 2023-05-09, 17:05:50
RE: SA Toc / Anchors Plugin - by multicolor - 2023-05-09, 20:31:17
RE: SA Toc / Anchors Plugin - by Hypertexter - 2023-05-24, 03:20:15
RE: SA Toc / Anchors Plugin - by Hypertexter - 2023-11-22, 01:00:09
RE: SA Toc / Anchors Plugin - by Knobbles - 2023-11-25, 03:28:09
RE: SA Toc / Anchors Plugin - by Hypertexter - 2023-11-28, 19:32:49
SA Toc / Anchors Plugin - by Oleg06 - 2012-02-25, 02:05:16
SA Toc / Anchors Plugin - by shawn_a - 2012-02-25, 02:10:04
SA Toc / Anchors Plugin - by shawn_a - 2012-02-25, 02:38:08
SA Toc / Anchors Plugin - by Oleg06 - 2012-02-25, 21:26:00
SA Toc / Anchors Plugin - by shawn_a - 2012-02-26, 04:17:01
SA Toc / Anchors Plugin - by Oleg06 - 2012-02-26, 20:51:13
SA Toc / Anchors Plugin - by shawn_a - 2012-02-27, 00:11:03
SA Toc / Anchors Plugin - by shawn_a - 2012-02-27, 02:57:07
SA Toc / Anchors Plugin - by ren! - 2012-03-20, 01:11:26
SA Toc / Anchors Plugin - by shawn_a - 2012-03-23, 00:20:54
SA Toc / Anchors Plugin - by ren! - 2012-03-24, 00:32:08
SA Toc / Anchors Plugin - by shawn_a - 2012-03-24, 03:34:43
SA Toc / Anchors Plugin - by ren! - 2012-03-26, 00:26:13
SA Toc / Anchors Plugin - by shawn_a - 2012-03-26, 03:35:08
SA Toc / Anchors Plugin - by surasshu - 2012-04-14, 09:41:45
SA Toc / Anchors Plugin - by shawn_a - 2012-04-14, 10:28:10
SA Toc / Anchors Plugin - by surasshu - 2012-04-14, 11:11:17
SA Toc / Anchors Plugin - by shawn_a - 2012-04-16, 00:34:42
SA Toc / Anchors Plugin - by shawn_a - 2012-04-16, 01:02:43
SA Toc / Anchors Plugin - by surasshu - 2012-04-16, 02:41:19
SA Toc / Anchors Plugin - by shawn_a - 2012-04-16, 08:19:56
SA Toc / Anchors Plugin - by surasshu - 2012-04-16, 10:04:54
SA Toc / Anchors Plugin - by shawn_a - 2012-04-16, 10:18:01
SA Toc / Anchors Plugin - by surasshu - 2012-04-16, 10:25:24
SA Toc / Anchors Plugin - by shawn_a - 2012-04-16, 11:29:46
SA Toc / Anchors Plugin - by surasshu - 2012-04-16, 13:35:19
SA Toc / Anchors Plugin - by shawn_a - 2012-04-16, 21:54:07
SA Toc / Anchors Plugin - by shawn_a - 2012-04-17, 02:48:17
SA Toc / Anchors Plugin - by surasshu - 2012-04-17, 14:32:02
SA Toc / Anchors Plugin - by shawn_a - 2012-04-20, 22:50:29
SA Toc / Anchors Plugin - by morvy - 2012-05-16, 23:42:37
SA Toc / Anchors Plugin - by shawn_a - 2012-05-17, 00:00:10
SA Toc / Anchors Plugin - by morvy - 2012-05-17, 00:11:58
SA Toc / Anchors Plugin - by morvy - 2012-06-01, 00:13:19
SA Toc / Anchors Plugin - by shawn_a - 2012-06-01, 06:38:57
SA Toc / Anchors Plugin - by morvy - 2012-06-01, 17:38:18
SA Toc / Anchors Plugin - by shawn_a - 2012-06-01, 23:15:56
SA Toc / Anchors Plugin - by yojoe - 2012-08-01, 18:42:34
SA Toc / Anchors Plugin - by shawn_a - 2012-08-01, 21:47:36
SA Toc / Anchors Plugin - by yojoe - 2012-08-01, 23:53:43
SA Toc / Anchors Plugin - by yojoe - 2012-08-13, 19:17:45
SA Toc / Anchors Plugin - by shawn_a - 2012-08-14, 02:41:56
SA Toc / Anchors Plugin - by yojoe - 2012-08-14, 03:26:30
SA Toc / Anchors Plugin - by shawn_a - 2012-08-14, 04:54:11
SA Toc / Anchors Plugin - by yojoe - 2012-08-14, 05:10:53
SA Toc / Anchors Plugin - by mvlcek - 2012-08-14, 05:53:50
SA Toc / Anchors Plugin - by yojoe - 2012-08-14, 06:56:05
SA Toc / Anchors Plugin - by shawn_a - 2012-08-14, 08:02:42
SA Toc / Anchors Plugin - by mvlcek - 2012-08-14, 15:57:00
SA Toc / Anchors Plugin - by shawn_a - 2012-08-14, 23:34:55
SA Toc / Anchors Plugin - by annathecrow - 2012-08-21, 20:48:50
SA Toc / Anchors Plugin - by yojoe - 2012-10-03, 00:53:10



Users browsing this thread: 1 Guest(s)