Unable to Save - Error on theme.inc

Carlos Miranda Levy - October 4, 2007 - 22:15
Project:Disk Node
Version:5.x-1.x-dev
Component:Code
Category:bug report
Priority:critical
Assigned:mooffie
Status:closed
Description

I was unable to open the browse window, so I moved the disknode folder to the core/modules directory and it works fine now.

But when I try to save a disknode or any node (say story with disknode as attachment), I get an error related to the theme:

Fatal error: Cannot use string offset as an array in X:\XXXXXX\xcorex\includes\theme.inc on line 552

The node is actually saved, and the attached file info is saved correctly. I can edit the node and see all the info (node/##/edit).

The error comes up when the node is shown (node/##)

This is a multisite config running Drupal 5.1 on a Windows 2003 server with XAMPP.

Line 552 of theme.inc is:

552 function theme_links($links, $attributes = array('class' => 'links')) {
553  $output = '';

I tried using garland or bluemarine, but still got the same error.
I have nicemenus running, by the way, but as I mentioned, the node is properly saved. The error comes up when displaying the node.

#1

Carlos Miranda Levy - October 4, 2007 - 23:27

Upgraded core to 5.2.
I disabled nicemenus, tinymce, bueditor and gmap, alinks, links, image attach and image assist.
There is no other module writing to the links section I believe.

The error persists.

do I have to manually enter a function in my theme or something?
The README file mentions a disknode_links function, but this function does not exist in the disknode.module file (there is a disknode_link function, though).

#2

batman1983 - October 28, 2007 - 23:57

I have the same error... on Drupal 5.3

#3

mooffie - November 6, 2007 - 06:26
Assigned to:Anonymous» mooffie
Status:active» patch (code needs work)

This should be easy to fix.

It happens on D5 when disknode is configured to be able to attach more than one file to a node. The code uses D4.7's way of doing links, so it crashes.

I'm attaching a patch. The patch isn't perfect because the real issue here is to get rid of D4.7 constructs. I hope to get involved in the development.

AttachmentSize
disknode.display_multiply_files.diff3.81 KB

#4

mooffie - November 7, 2007 - 12:26
Status:patch (code needs work)» fixed

Fixed.
http://drupal.org/cvs?commit=87195

#5

batman1983 - November 7, 2007 - 23:05

I don't why, but i still get this error. I hope, i don't have to upload 10 downloads every time. I'd like to upload up to 10 files.

#6

mooffie - November 8, 2007 - 15:24

I don't why, but i still get this error.

That's because drupal.org packages the development snapshots "nightly". The new snapshot was available for download on 01:03 GMT, which is 58 minutes after you posted this message. Please download again.

#7

batman1983 - November 8, 2007 - 21:10

Now it works, thanks!!!

#8

Anonymous - November 22, 2007 - 21:11
Status:fixed» closed

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

 
 

Drupal is a registered trademark of Dries Buytaert.