The $result variable is supposed to be passed by reference according to http://api.drupal.org/api/function/custom_url_rewrite_inbound/6

However, that's not happening. Here's a patch to fix.

CommentFileSizeAuthor
custom_url_rewrite_fix.patch465 bytesSteve Dondley
Support from Acquia helps fund testing for Drupal Acquia logo

Comments

Damien Tournoud’s picture

Assigned: Steve Dondley » Unassigned
Priority: Critical » Normal
Status: Needs review » Closed (works as designed)

In PHP, passing by reference is a property of the function signature, not of the call (please review the PHP manual page about this [1]).

Thus, there is no bug here. You just have to make sure that your implementation of custome_url_rewrite_inbound() has the correct signature:

function custom_url_rewrite_inbound(&$result, $path, $path_language)

[1] http://php.net/manual/en/language.references.pass.php