Compile error in nodehierarchy_views.module

joneian - December 12, 2008 - 22:37
Project:Node Hierarchy
Version:6.x-1.2
Component:Code
Category:bug report
Priority:normal
Assigned:Unassigned
Status:closed
Description

Hi,

I've just installed node hierarchy. I turned on Node Hierarcy, saved and then turned on Node Hierarchy Views Embed and got the following error:

Fatal error: Only variables can be passed by reference in \sites\all\modules\nodehierarchy\nodehierarchy_views\nodehierarchy_views.module on line 99

I installed node hierarchy 6.x_1.1, on Drupal 6.6.

Cheers,
Ian

#1

joneian - December 14, 2008 - 19:19

I guess this is because I'm using an older version of PHP (4.4.7).

I was able to fix the issue by changing:
    $first_arg = current((array)$view->display['default']->display_options['arguments']);

to:
    $first_arg = current($tmp = (array)$view->display['default']->display_options['arguments']);

See this post

Cheers,
Ian

#2

jinesh.m - February 11, 2009 - 23:05
Version:6.x-1.1» 6.x-1.2

I installed node hierarchy 6.x_1.2 on Drupal 6.9 and got a similar fatal error as the one described previously, except it was on line 133. im using an older version of PHP (4.3.10).

applying the above fix resolved the issue.

#3

ronan - February 15, 2009 - 05:51

Thanks for the reports. I don't run php 4 anywhere anymore, so I missed this. I've applied the patch (with a slight modification and an explanatory comment). Let me know if the latest dev runs on php 4 now.

Thanks
Ronan

#4

ronan - February 15, 2009 - 06:00
Status:active» fixed

#5

System Message - March 1, 2009 - 06:10
Status:fixed» closed

Automatically closed -- issue fixed for 2 weeks with no activity.

 
 

Drupal is a registered trademark of Dries Buytaert.