white page with error

Babalu - September 29, 2008 - 08:42
Project:Keyboard shortcut utility
Version:6.x-1.1
Component:Code
Category:bug report
Priority:critical
Assigned:BravoGolf
Status:closed
Description

when i go under admin/settings/shortcut it comes a white page with this error:

Fatal error: Unsupported operand types in /var/www/web3/html/includes/common.inc on line 1445

#1

skyredwang - October 6, 2008 - 21:46

Same here

#2

dorion - October 9, 2008 - 12:16
Priority:normal» critical
Assigned to:Anonymous» dorion
Status:active» needs review

This is my patch to slove your probem. Please test it!

The error is the third paramater of the l() function, it must be an array()!

AttachmentSize
shortcut_6_1_314740.patch 578 bytes

#3

Babalu - October 10, 2008 - 10:36

hmm no. after patching the same problem still there

#4

pebosi - November 20, 2008 - 20:26
Status:needs review» reviewed & tested by the community

When using the 1.1 Version and applying the patch the error is gone and shortcuts work.

regards

#5

meet.h.thakkar - March 20, 2009 - 08:46

Eureka !! I got the problem

see the code

<?php
function theme_shortcut_admin_list($shortcuts = array()) {
 
$headers = array(t('Shortcut'), t('Description'), t('Actions'));
 
$rows = array();
  foreach (
$shortcuts as $shortcut) {
   
$shortcut_string = shortcut_shortcut_to_string($shortcut);
   
$rows[] = array(
       
$shortcut_string,
       
$shortcut['title'],
       
l(t('Edit'), 'node/' . $shortcut['nid'] . '/edit', array(drupal_get_destination()))  // enclose  array() to  drupal_get_destination()
       
. ' | '
       
. l(t('Remove'), 'node/' . $shortcut['nid'] . '/delete', array(drupal_get_destination()))    // enclose  array() to  drupal_get_destination()
     
);
  }
 
$output = l(t('Add a new shortcut'), 'node/add/shortcut', array(drupal_get_destination()));  // enclose  array() to  drupal_get_destination()

?>

and its done

#6

meet.h.thakkar - March 24, 2009 - 10:37

#7

Jerimee - June 22, 2009 - 01:36

this seemed to fix it - can this solution be added to release?

#8

pebosi - June 24, 2009 - 08:04
Version:6.x-1.0» 6.x-1.1
Status:reviewed & tested by the community» needs review

Created a patch of #5 with small modification.

regards

AttachmentSize
shortcut-314740.patch 1.18 KB

#9

Babalu - June 24, 2009 - 09:09

#5 code works
#8 patch is not working for me

#10

pebosi - June 24, 2009 - 09:38

can you specify whats not working with the patch?

#11

vstmusic - July 29, 2009 - 17:13

It works with #5 !!

Thanks for this nice practical module !!!

#12

BravoGolf - August 18, 2009 - 13:02
Assigned to:dorion» BravoGolf
Status:needs review» fixed

Patch/code in #5 worked for me.

#13

System Message - September 1, 2009 - 13:10
Status:fixed» closed

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

 
 

Drupal is a registered trademark of Dries Buytaert.