When enabling the module you will receive plenty of warnings like the one bellow:

warning: Parameter 2 to taxonomy_treemenu_menu_link_alter() expected to be a reference, value given in /srv/www/vhosts/drupal/6.16/includes/common.inc on line 2839

As far as I know it is one of those simple PHP 5.3 related issues...
Drupal host is a LAMP server running PHP v5.3.

Anyone with know-how, feel free to fix this.

Contact me if I can be of any help.

Comments

lazarus477’s picture

Status: Active » Needs review
StatusFileSize
new585 bytes

Ok I edited the module and got it installed without any errors. Thoroughly tested it and it appears to work well. Have made a patch which I am attaching. Bare in mind it is my first patch ever so if anything is wrong please inform me.

aquila’s picture

This patch seems reasonable to me, but confirmation of the developers would be good.

rcrowther’s picture

Note for aquila,

I can understand your wish for developer confirmation. Unfortunately, I am now working backwards in that I am not maintaining, and I can't test.

I can't speak for the loss of the reference. But the effect of the code is straightforward, it takes an admin link or two straight back to where they came from. Upshot, if removed and it failed, this would cause no major damage to functionality, simply that some admin would not be as slick as expected.

If by 'Thoroughly tested' lazarus means he knows the links did this, and they continue to so so, the patch is good.

Rob

dkane’s picture

I was getting the above mentioned error after going live with a site running PHP 5.3.2 after developing in my local MAMP environment of php 5.2. The error didn't really affect anything, and it only showed up whenever I ran update.php or cleared the caches, but errors still annoy me regardless. Anyway, applying your patch got rid of the errors. Thanks for your work on this lazarus!

netprotocal’s picture

How do you install this patch?

tedbow’s picture

Priority: Critical » Normal
StatusFileSize
new616 bytes

I have attached an update patch for this issue.

The patch in #1 gets rid of the warning but the $item argument still should be by reference b/c this is an alter hook.

See docs for drupal_alter here:http://api.drupal.org/api/drupal/includes!module.inc/function/drupal_alt...

Also I am changing this from critical to normal because this is only a php warning not an error. The functionality still works.
In production sites you can turn off these messages.

@netprotocal and others for info on applying patches see http://drupal.org/patch/apply