In email notification about new relationships I recived link : http://www.site.com/connections/received which is wrong for me.
I need something like: http://www.site.com/users/UserName/community/received

Also I can't find the way to translate those email messages. I translated everything else.

THX

Comments

gaba’s picture

Title: Wrong link i email notification » Wrong link in email notification
gaba’s picture

Status: Active » Fixed

Answer = rule settings.

Status: Fixed » Closed (fixed)

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

As If’s picture

That was a completely unsatisfactory answer (even if you're just answering yourself). The module doesn't even use the path it is sending out. The proper path should be user/%/community/received and anything else is a fail.

For anyone in this situation - maybe you're upgrading a busy production site for a paying client who expected this to be an easy replacement for D5's Buddylist, with no experience using Rules and no desire to install unstable modules on their site... Here's an alternative:

1. Create a Page. Make the body PHP Format and the body of the page will look like this:

<?php
global $user;
if($user->uid) { $jumpto = 'user/' . $user->uid . '/community/received'; } else { $jumpto = 'user'; }
drupal_goto($jumpto);
?>

2. The page's URL Path Settings should be:
connections/received

The same approach may be used for any other bogus links this module sends out.

As If’s picture

ADDITIONAL IMPORTANT NOTE: The redirect has the potential to derail the search indexer, as related here. To make sure this doesn't happen, you have to wrap your logic in an IF statement to make sure the goto only happens when arg(0) == 'node'. Here is a corrected code sample...

<?php
global $user;
if(arg(0) == 'node') {
  if($user->uid) {
    $jumpto = 'user/' . $user->uid . '/community/received';
  } else {
    $jumpto = 'user';
  }
  drupal_goto($jumpto);
}
?>