There is a new hook in Drupal 7.17 called hook_entity_view_mode_alter() that gets invoked whenever an entity is being viewed. This would be much more reliable to use compared to hook_init() and hook_url_inbound_alter() for checking if $view_mode == 'full' and the current page does not match entity_uri().

Comments

dave reid’s picture

Status: Active » Needs review
StatusFileSize
new2.52 KB
deanflory’s picture

Issue summary: View changes

Patch #1 fails against the latest dev (2015-Jan-05):

patching file redirect.module
Hunk #1 FAILED at 250.
1 out of 1 hunk FAILED -- saving rejects to file redirect.module.rej

dave reid’s picture

Status: Needs review » Needs work

The last submitted patch, 1: 2074647-entity-view-full-redirect.patch, failed testing. View results

tomsegarra’s picture

Status: Needs work » Needs review
StatusFileSize
new2.58 KB

This applies the patch from #1 to the latest dev. This issue is not addressed in the related #905914: Merge global redirect functions into Redirect module.

chris matthews’s picture

Related issues: +#905914: Merge global redirect functions into Redirect module

The patch in #5 applied cleanly to redirect.admin.inc and redirect.module 7.x-1.x-dev and looks like a clean fix, but it would be good to get at least 1 other review/test before changing the status to RTBC.

chris matthews’s picture

This issue is a child of #2514248: Plan for Redirect v7.x-1.0 release. Should it continue to be blocker for a full 7.x-1.0 release of redirect?

euk’s picture

I have applied the patch on top of 7.x-1.x-dev , but can't see any difference. Variable redirect_global_entity_view_full apparently has no way to be configured in the admin interface - "Globals" fieldset is disabled via #access set to FALSE, and thus the patch has no affect at all.

euk’s picture

Status: Needs review » Needs work

Couldn't see any affect of the patch.

wylbur’s picture

Status: Needs work » Closed (outdated)

Closing this as Outdated as Drupal 7 is EOL.