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

CommentFileSizeAuthor
#8 shortcut-314740.patch1.18 KBpebosi
#2 shortcut_6_1_314740.patch578 bytesdorion

Comments

skyredwang’s picture

Same here

dorion’s picture

Assigned: Unassigned » dorion
Priority: Normal » Critical
Status: Active » Needs review
StatusFileSize
new578 bytes

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()!

Babalu’s picture

hmm no. after patching the same problem still there

pebosi’s picture

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

meet.h.thakkar’s picture

Eureka !! I got the problem

see the code



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

meet.h.thakkar’s picture

Jerimee’s picture

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

pebosi’s picture

Version: 6.x-1.0 » 6.x-1.1
Status: Reviewed & tested by the community » Needs review
StatusFileSize
new1.18 KB

Created a patch of #5 with small modification.

regards

Babalu’s picture

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

pebosi’s picture

can you specify whats not working with the patch?

vstmusic’s picture

It works with #5 !!

Thanks for this nice practical module !!!

BravoGolf’s picture

Assigned: dorion » BravoGolf
Status: Needs review » Fixed

Patch/code in #5 worked for me.

Status: Fixed » Closed (fixed)

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