Textpattern Forum

You are not logged in. Register | Login | Help

#161 2010-04-06 21:52:01

gomedia
Plugin Author
Registered: 2008-06-01
Posts: 919
Website

Re: adi_menu – section hierarchy, section menu and breadcrumb trail

bmwg wrote:

I get domain.com/section links. is it possible to get domain.com/section/subsection?

That’s the Holy Grail your looking for then! Sorry, don’t know how to achieve that. I’m not enough of an htaccess expert to figure that one out.

Offline

#162 2010-05-28 10:43:29

caruso_g
Member
From: Catania
Registered: 2009-04-11
Posts: 88
Website

Re: adi_menu – section hierarchy, section menu and breadcrumb trail

Hi Adi,
was thinking if it could be possible to add an option to redirect menu items to custom addresses.
For example, I have a support section of a client’s website that should link to his account on Zendesk.com
What about a solution like in this quick mockup?

If not, any solution?

Thanks for your help

Offline

#163 2010-08-08 17:42:31

jcd
Member
Registered: 2010-04-15
Posts: 12

Re: adi_menu – section hierarchy, section menu and breadcrumb trail

Hi adi,

thanks for writing this wonderful plugin and for including the current_children_only option in the 0.12beta release!
There is one problem though I encountered with this new option. Let’s say I have a section hierarchy similar to this:

A
-A1
-A2
B
-B1
-B2

I set active_ancestors=“0” since I only want the active section to be highlighted, not its parents. At first only A and B are visible in the menu, as expected when using current_children_only=“1”. When I click A, the subsections A1 and A2 appear, as expected. As soon as I click on a subsection like A1 though, the menu collapses back to the first level. Only A and B are visible in the menu, but the browser actually is on page A1. With active_ancestors=“1” it doesn’t happen, but that can be only a temporary solution since I really only want one section at a time to be highlighted. Is there a solution to this, maybe I am missing something?

Also, where can I donate for the plugin? Thanks!

jcd

Offline

#164 2010-08-08 20:46:35

gomedia
Plugin Author
Registered: 2008-06-01
Posts: 919
Website

Re: adi_menu – section hierarchy, section menu and breadcrumb trail

jcd wrote:

thanks for writing this wonderful plugin and for including the current_children_only option in the 0.12beta release!

Hi jcd, my pleasure.

There is one problem though I encountered with this new option. Let’s say I have a section hierarchy similar to this:

A
-A1
-A2
B
-B1
-B2

I set active_ancestors=“0” since I only want the active section to be highlighted, not its parents.

active_ancestors="0" is the default position, so you don’t have to explicitly set it – but it shouldn’t do any harm.

At first only A and B are visible in the menu, as expected when using current_children_only=“1”. When I click A, the subsections A1 and A2 appear, as expected. As soon as I click on a subsection like A1 though, the menu collapses back to the first level. Only A and B are visible in the menu, but the browser actually is on page A1. With active_ancestors=“1” it doesn’t happen, but that can be only a temporary solution since I really only want one section at a time to be highlighted. Is there a solution to this, maybe I am missing something?

Hmm, I can see that happening too. It’s not immediately obvious why fiddling with an active class setting should affect which sections are output. I’ll have to think about that one! Perhaps as a temporary measure you could do something in CSS to un-highlight the ancestor section?

Also, where can I donate for the plugin? Thanks!

That’s very kind of you. You’re very welcome to donate, but not to me, make a donation to the Textpattern developers – they’re the ones who do the hard work, I just muck around on the fringes.

Cheers, Adi.

Offline

#165 2010-08-08 20:49:13

gomedia
Plugin Author
Registered: 2008-06-01
Posts: 919
Website

Re: adi_menu – section hierarchy, section menu and breadcrumb trail

caruso_g wrote:

was thinking if it could be possible to add an option to redirect menu items to custom addresses.

Just for the record, I’ve provided caruso_g with a lata-beta of adi_menu with this functionality. There’re other enhancements afoot, so it’s not ready for general abuse but if anyone wants to have a play, let me know.

Offline

#166 2010-08-09 09:08:16

caruso_g
Member
From: Catania
Registered: 2009-04-11
Posts: 88
Website

Re: adi_menu – section hierarchy, section menu and breadcrumb trail

Adi made a great work.
I am heavily testing it and, so far (1 month), it is working great.
The new redirect option is working smoothly. It is really the option the plugin needed, now it is practically perfect.
I really think it should be included into TXP standard release (hint, hint, core devs…

Thanks so much for developing this plugin, it helps so much in our day by day work and you deserve this public thanks.

Offline

#167 2010-08-09 09:45:49

jcd
Member
Registered: 2010-04-15
Posts: 12

Re: adi_menu – section hierarchy, section menu and breadcrumb trail

gomedia wrote:

You’re very welcome to donate, but not to me, make a donation to the Textpattern developers – they’re the ones who do the hard work, I just muck around on the fringes.

Done, and thanks again for your work.

Offline

#168 2010-08-11 18:18:01

jcd
Member
Registered: 2010-04-15
Posts: 12

Re: adi_menu – section hierarchy, section menu and breadcrumb trail

Hi adi,

I came across a problem, maybe you know a solution. When I call adi_menu_breadcrumb more than once, I get this error message:

Fatal error: Cannot redeclare adi_menu_lineage() (previously declared in /…/textpattern/lib/txplib_misc.php(594) : eval()’d code:579) in /…/textpattern/lib/txplib_misc.php(594) : eval()’d code on line 579

I want to call adi_menu_breadcrumb multiple times because I want to use it to generate the content of the <title> and <h1> tags like this:

<txp:adi_menu_breadcrumb link="0" default_title="Page Title" escape="htmlspecial" label="" separator=": " include_default="0" />

and of course once more for the actual linked breadcrumb trail.

Offline

#169 2010-08-11 22:02:55

gomedia
Plugin Author
Registered: 2008-06-01
Posts: 919
Website

Re: adi_menu – section hierarchy, section menu and breadcrumb trail

jcd wrote:

Fatal error: Cannot redeclare adi_menu_lineage() (previously declared in /…/textpattern/lib/txplib_misc.php(594) : eval()’d code:579) in /…/textpattern/lib/txplib_misc.php(594) : eval()’d code on line 579

Hi jcd. Now, that’s interesting …

Offline

#170 2010-08-19 23:51:25

gomedia
Plugin Author
Registered: 2008-06-01
Posts: 919
Website

Re: adi_menu – section hierarchy, section menu and breadcrumb trail

Version 0.12 now available.

  • new attribute ‘current_children_only’ (for ttr & caruso_g)
  • enhancement: new (automatic) way of coping with accented characters (thanks ttr)
  • enhancement: minor admin tab improvements
  • fix: error when adi_menu_breadcrumb used more than once on a page (thanks jcd)
  • fix: current_children_only not functioning correctly (thanks jcd)
  • fix: couple of uninitialised variables generating error_log messages (lines 827, 837)

… apologies for filling up your error log files :-(

I’m hoping that this will be the last 0.x version of adi_menu. The plan(!) is that the next will be 1.0 which will have section redirect, alternative section titles and the new article system.

Offline

Board footer

Powered by FluxBB