diff options
author | Angie Byron <webchick@24967.no-reply.drupal.org> | 2010-02-11 15:52:13 +0000 |
---|---|---|
committer | Angie Byron <webchick@24967.no-reply.drupal.org> | 2010-02-11 15:52:13 +0000 |
commit | 52195a6b1dd478875a93935df27d7bcacb14f289 (patch) | |
tree | 052233b34e4c6a9a0d6268426e650500817265f6 /modules/comment/comment.module | |
parent | 30ae1fb5596cc59e27717262a04e6447d27cebb4 (diff) | |
download | brdo-52195a6b1dd478875a93935df27d7bcacb14f289.tar.gz brdo-52195a6b1dd478875a93935df27d7bcacb14f289.tar.bz2 |
#525622 by scor, catch, and yched: Allow Entity path callback to deal with options.
Diffstat (limited to 'modules/comment/comment.module')
-rw-r--r-- | modules/comment/comment.module | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/modules/comment/comment.module b/modules/comment/comment.module index 66dec2e7c..ee0f0764f 100644 --- a/modules/comment/comment.module +++ b/modules/comment/comment.module @@ -97,7 +97,7 @@ function comment_entity_info() { 'comment' => array( 'label' => t('Comment'), 'base table' => 'comment', - 'path callback' => 'comment_path', + 'uri callback' => 'comment_uri', 'fieldable' => TRUE, 'controller class' => 'CommentController', 'object keys' => array( @@ -148,10 +148,13 @@ function comment_node_type_load($name) { } /** - * Entity path callback. + * Entity uri callback. */ -function comment_path($comment) { - return 'comment/' . $comment->cid; +function comment_uri($comment) { + return array( + 'path' => 'comment/' . $comment->cid, + 'options' => array('fragment' => 'comment-' . $comment->cid), + ); } /** |