Discussion:
dw-free: http://bugs.dwscoalition.org/show_bug.cgi?id=2718
Dreamwidth Changelog
2011-05-02 11:55:48 UTC
Permalink
Change user-facing text to notifications/tracked items as appropriate.

Patch by ninetydegrees.

diffs (200 lines):

diff -r 349e60113ca0 -r 034efde6e7ca bin/upgrading/en.dat
--- a/bin/upgrading/en.dat Mon May 02 19:39:53 2011 +0800
+++ b/bin/upgrading/en.dat Mon May 02 19:54:51 2011 +0800
@@ -3565,7 +3565,7 @@ subscribe_interface.manage_settings=Mana

subscribe_interface.nosubs.text=Track entries, comments, and account updates by clicking the [[img]] icon or the "Track This" link that appears on entries, comments, and the Profile page.

-subscribe_interface.nosubs.title=You don't have any subscriptions
+subscribe_interface.nosubs.title2=You aren't tracking any items

subscribe_interface.notify_me=Notify me when...

@@ -3575,7 +3575,7 @@ subscribe_interface.save=Save

subscribe_interface.special_subs.note=These notification options are only available by email and won't show in your [[sitenameabbrev]] Inbox.

-subscribe_interface.subs.total=You are using [[active]] out of [[max_active]] active subscriptions.
+subscribe_interface.subs.total2=You are using [[active]] out of [[max_active]] active notifications.

subscribe_interface.unavailable_subs.note=These notification options are only available to certain account types.

diff -r 349e60113ca0 -r 034efde6e7ca cgi-bin/LJ/Subscription.pm
--- a/cgi-bin/LJ/Subscription.pm Mon May 02 19:39:53 2011 +0800
+++ b/cgi-bin/LJ/Subscription.pm Mon May 02 19:54:51 2011 +0800
@@ -613,8 +613,8 @@ sub as_string {
sub as_string {
my $self = shift;
my $max = $self->field('u')->count_max_subscriptions;
- return 'The subscription "' . $self->field('subscr')->as_html . '" was not saved because you have' .
- " reached your limit of $max active subscriptions. Subscriptions need to be deactivated before more can be added.";
+ return 'The notification tracking "' . $self->field('subscr')->as_html . '" was not saved because you have' .
+ " reached your limit of $max active notifications. Notifications need to be deactivated before more can be added.";
}

# Too many subscriptions exist, not necessarily active
@@ -625,8 +625,8 @@ sub as_string {
sub as_string {
my $self = shift;
my $max = $self->field('max');
- return 'The subscription "' . $self->field('subscr')->as_html . '" was not saved because you have' .
- " more than $max existing subscriptions. Subscriptions need to be completely removed before more can be added.";
+ return 'The notification tracking "' . $self->field('subscr')->as_html . '" was not saved because you have' .
+ " more than $max existing notifications. Notifications need to be completely removed before more can be added.";
}

1;
diff -r 349e60113ca0 -r 034efde6e7ca cgi-bin/weblib.pl
--- a/cgi-bin/weblib.pl Mon May 02 19:39:53 2011 +0800
+++ b/cgi-bin/weblib.pl Mon May 02 19:54:51 2011 +0800
@@ -3629,7 +3629,7 @@ sub subscribe_interface {

# show blurb if not tracking anything
if ($cat_empty && $is_tracking_category) {
- my $blurb = "<?p <strong>" . LJ::Lang::ml('subscribe_interface.nosubs.title') . "</strong><br />";
+ my $blurb = "<?p <strong>" . LJ::Lang::ml('subscribe_interface.nosubs.title2') . "</strong><br />";
$blurb .= LJ::Lang::ml( 'subscribe_interface.nosubs.text',
{ img => LJ::img( 'track', '', { align => 'absmiddle',
alt => $ui_notify } ) } ) . " p?>";
@@ -3685,7 +3685,7 @@ sub subscribe_interface {
# max for total number of subscriptions (generally it is $paid_max)
my $system_max = $u_max > $paid_max ? $u_max : $paid_max;

- $subscription_stats .= "<div class='subscription_stats'>" . LJ::Lang::ml( 'subscribe_interface.subs.total', {
+ $subscription_stats .= "<div class='subscription_stats'>" . LJ::Lang::ml( 'subscribe_interface.subs.total2', {
active => $max_active_method,
max_active => $u_max,
total => $max_total_method,
diff -r 349e60113ca0 -r 034efde6e7ca htdocs/manage/index.bml
--- a/htdocs/manage/index.bml Mon May 02 19:39:53 2011 +0800
+++ b/htdocs/manage/index.bml Mon May 02 19:54:51 2011 +0800
@@ -147,7 +147,7 @@ _code?>
my $remote = LJ::get_remote();

if ($remote && $remote->can_use_esn) {
- return '<li><a href="/manage/subscriptions/" title="<?_ml .manage.subscriptions.about _ml?>"><?_ml .manage.subscriptions _ml?></a></li>';
+ return '<li><a href="/manage/subscriptions/" title="<?_ml .manage.notifications.about _ml?>"><?_ml .manage.notifications _ml?></a></li>';
} else {
return '';
}
diff -r 349e60113ca0 -r 034efde6e7ca htdocs/manage/index.bml.text
--- a/htdocs/manage/index.bml.text Mon May 02 19:39:53 2011 +0800
+++ b/htdocs/manage/index.bml.text Mon May 02 19:54:51 2011 +0800
@@ -105,9 +105,9 @@

.manage.logins=Manage Logins

-.manage.subscriptions=Manage Message Settings
+.manage.notifications=Manage Notification Options

-.manage.subscriptions.about=Manage notifications and subscriptions
+.manage.notifications.about=Manage your notification tracking options

.mobile.settings=Mobile Settings

diff -r 349e60113ca0 -r 034efde6e7ca htdocs/manage/settings/index.bml
--- a/htdocs/manage/settings/index.bml Mon May 02 19:39:53 2011 +0800
+++ b/htdocs/manage/settings/index.bml Mon May 02 19:54:51 2011 +0800
@@ -205,7 +205,7 @@ body<=

if ( $given_cat eq "notifications" && $POST{deleteinactive} ) {
$u->delete_all_inactive_subscriptions;
- $submit_msg .= "<?errorbar $ML{'.success.deleteinactive'} errorbar?><br />";
+ $submit_msg .= "<?errorbar $ML{'.success.deleteinactive2'} errorbar?><br />";
} elsif ( $given_cat eq "notifications" ) {
my @notif_errors;

@@ -429,10 +429,10 @@ body<=
$ret .= "<div id='settings_save' class='action-bar'>";
$ret .= $cats_with_settings{$given_cat}->{form} ? LJ::html_submit($ML{'.btn.save'}) : "&nbsp;";
$ret .= "&nbsp;";
- my $del_conf = LJ::ejs( $ML{'.confirm.deleteinactive'} );
- $ret .= LJ::html_submit( 'deleteinactive', $ML{'.btn.deleteinactive'}, {
+ my $del_conf = LJ::ejs( $ML{'.confirm.deleteinactive2'} );
+ $ret .= LJ::html_submit( 'deleteinactive', $ML{'.btn.deleteinactive2'}, {
class => 'btn',
- title => $ML{'.btn.deleteinactive'},
+ title => $ML{'.btn.deleteinactive2'},
onClick => "return confirm( '$del_conf' )"
} );
$ret .= "</div>";
@@ -564,10 +564,10 @@ body<=
$ret .= $cats_with_settings{$given_cat}->{form} ? LJ::html_submit($ML{'.btn.save'}) : "&nbsp;";
if ( $given_cat eq "notifications" ) {
$ret .= "&nbsp;";
- my $del_conf = LJ::ejs( $ML{'.confirm.deleteinactive'} );
- $ret .= LJ::html_submit( 'deleteinactive', $ML{'.btn.deleteinactive'}, {
+ my $del_conf = LJ::ejs( $ML{'.confirm.deleteinactive2'} );
+ $ret .= LJ::html_submit( 'deleteinactive', $ML{'.btn.deleteinactive2'}, {
class => 'btn',
- title => $ML{'.btn.deleteinactive'},
+ title => $ML{'.btn.deleteinactive2'},
onClick => "return confirm( '$del_conf' )"
} );
}
diff -r 349e60113ca0 -r 034efde6e7ca htdocs/manage/settings/index.bml.text
--- a/htdocs/manage/settings/index.bml.text Mon May 02 19:39:53 2011 +0800
+++ b/htdocs/manage/settings/index.bml.text Mon May 02 19:54:51 2011 +0800
@@ -13,7 +13,7 @@

.bdayreminder=Receive email reminders for the birthdays of people in your Circle.

-.btn.deleteinactive=Delete all inactive subscriptions
+.btn.deleteinactive2=Delete all inactive tracked items

.btn.save=Save

@@ -49,7 +49,7 @@

.commentpage.text=When you follow a comment link from your Reading page, you can view that comment page in your own journal style.

-.confirm.deleteinactive=Are you sure you want to delete all inactive subscriptions?
+.confirm.deleteinactive2=Are you sure you want to delete all inactive tracked items?

.contextualhover=Show contextual hover menu

@@ -161,7 +161,7 @@

.success=You've successfully saved your account settings.

-.success.deleteinactive=You have successfully deleted all inactive subscriptions.
+.success.deleteinactive2=You have successfully deleted all inactive tracked items.

.success.header=Success!

diff -r 349e60113ca0 -r 034efde6e7ca htdocs/tools/endpoints/esn_subs.bml
--- a/htdocs/tools/endpoints/esn_subs.bml Mon May 02 19:39:53 2011 +0800
+++ b/htdocs/tools/endpoints/esn_subs.bml Mon May 02 19:54:51 2011 +0800
@@ -59,7 +59,7 @@ _c?>

$subscr->delete;
$success = 1;
- $ret{msg} = "Subscription deleted";
+ $ret{msg} = "Notification Tracking Removed";
$ret{subscribed} = 0;


@@ -75,12 +75,12 @@ _c?>
}
} elsif ($action eq 'addsub') {

- return $err->("Reached limit of " . $remote->count_max_subscriptions . " active subscriptions")
+ return $err->("Reached limit of " . $remote->count_max_subscriptions . " active notifications")
unless $remote->can_add_inbox_subscription;

my %subparams = ();

- return $err->("Invalid subscription parameters") unless (defined $POST{journalid}) && $POST{etypeid}+0;
+ return $err->("Invalid notification tracking parameters") unless (defined $POST{journalid}) && $POST{etypeid}+0;

foreach my $param (qw(journalid etypeid arg1 arg2)) {
$subparams{$param} = $POST{$param}+0;
@@ -97,7 +97,7 @@ _c?>
if ($subscr) {
$subscr->activate;
$success = 1;
- $ret{msg} = "Subscribed";
+ $ret{msg} = "Notification Tracking Added";
$ret{subscribed} = 1;
$ret{event_class} = $subscr->event_class;
my %sub_info = $subscr->sub_info;
Dreamwidth Changelog
2011-05-03 03:18:59 UTC
Permalink
Move files over; edit redirects and URLs. /manage/subscriptions/user(or comment or entry) now goes to /manage/tracking/... /manage/subscriptions/filters is still in the same place. /manage/subscriptions/ now points to /manage/subscriptions/filters

Patch by ninetydegrees.

diffs (1012 lines):

diff -r 4cf824f91dc2 -r 61e82aece0c1 bin/upgrading/en.dat
--- a/bin/upgrading/en.dat Mon May 02 21:13:34 2011 +0800
+++ b/bin/upgrading/en.dat Tue May 03 11:18:42 2011 +0800
@@ -1099,13 +1099,13 @@ Or you can:
Or you can:
.

-esn.footer.text<<
+esn.footer.text2<<
--
[[sitenameshort]] Team
[[sitename]]
[[hook]]

-If you'd rather not get these updates, you can change your preferences at [[siteroot]]/manage/subscriptions/
+If you'd rather not get these updates, you can change your preferences at [[siteroot]]/manage/settings/?cat=notifications
.

esn.here_you_can=From here you can:
diff -r 4cf824f91dc2 -r 61e82aece0c1 bin/upgrading/s2layers/siteviews/layout.s2
--- a/bin/upgrading/s2layers/siteviews/layout.s2 Mon May 02 21:13:34 2011 +0800
+++ b/bin/upgrading/s2layers/siteviews/layout.s2 Tue May 03 11:18:42 2011 +0800
@@ -73,7 +73,7 @@ function IconsPage::print_body() {
if ( $.can_manage ) {
"""Would you like to <a href="$*SITEROOT/editpics">upload a new icon or edit your icon keywords, comments, and descriptions</a>?""";
} else {
- """We can <a href="$*SITEROOT/manage/subscriptions/user?journal=$.journal.username">notify</a> you when this account uploads a new one.""";
+ """We can <a href="$*SITEROOT/manage/tracking/user?journal=$.journal.username">notify</a> you when this account uploads a new one.""";
}
"""</p><p>""";
var int sort_ct = 0;
diff -r 4cf824f91dc2 -r 61e82aece0c1 cgi-bin/DW/Logic/UserLinkBar.pm
--- a/cgi-bin/DW/Logic/UserLinkBar.pm Mon May 02 21:13:34 2011 +0800
+++ b/cgi-bin/DW/Logic/UserLinkBar.pm Tue May 03 11:18:42 2011 +0800
@@ -351,7 +351,7 @@ sub track {
}

if ( $remote && $remote->can_use_esn ) {
- $link->{url} = "manage/subscriptions/user?journal=$user";
+ $link->{url} = "manage/tracking/user?journal=$user";
$link->{class} = "trackuser";
$link->{image} = 'track.png';
} else {
diff -r 4cf824f91dc2 -r 61e82aece0c1 cgi-bin/LJ/NotificationMethod/Email.pm
--- a/cgi-bin/LJ/NotificationMethod/Email.pm Mon May 02 21:13:34 2011 +0800
+++ b/cgi-bin/LJ/NotificationMethod/Email.pm Tue May 03 11:18:42 2011 +0800
@@ -81,7 +81,7 @@ sub notify {
croak "invalid event passed" unless ref $ev;

$vars->{'hook'} = LJ::Hooks::run_hook("esn_email_footer", $ev, $u);
- my $footer = LJ::Lang::get_text($lang, 'esn.footer.text', undef, $vars);
+ my $footer = LJ::Lang::get_text($lang, 'esn.footer.text2', undef, $vars);

my $plain_body = LJ::Hooks::run_hook("esn_email_plaintext", $ev, $u);
unless ($plain_body) {
diff -r 4cf824f91dc2 -r 61e82aece0c1 cgi-bin/LJ/S2.pm
--- a/cgi-bin/LJ/S2.pm Mon May 02 21:13:34 2011 +0800
+++ b/cgi-bin/LJ/S2.pm Tue May 03 11:18:42 2011 +0800
@@ -3251,7 +3251,7 @@ sub _Comment__get_link

my $etypeid = 'LJ::Event::JournalNewComment'->etypeid;

- return LJ::S2::Link( "$LJ::SITEROOT/manage/subscriptions/comments?journal=$u->{'user'}&amp;talkid=" . $comment->dtalkid,
+ return LJ::S2::Link( "$LJ::SITEROOT/manage/tracking/comments?journal=$u->{'user'}&amp;talkid=" . $comment->dtalkid,
$ctx->[S2::PROPS]->{"text_multiform_opt_untrack"},
LJ::S2::Image_std( 'untrack' ),
'lj_etypeid' => $etypeid,
@@ -3308,12 +3308,12 @@ sub _Comment__get_link
$btn_params{'js_swapname'} = $ctx->[S2::PROPS]->{text_multiform_opt_untrack};

if ($key eq "watch_thread" && !$watching_parent) {
- return LJ::S2::Link( "$LJ::SITEROOT/manage/subscriptions/comments?journal=$u->{'user'}&amp;talkid=$dtalkid",
+ return LJ::S2::Link( "$LJ::SITEROOT/manage/tracking/comments?journal=$u->{'user'}&amp;talkid=$dtalkid",
$ctx->[S2::PROPS]->{"text_multiform_opt_track"},
LJ::S2::Image_std( 'track' ), %btn_params );
}
if ($key eq "watching_parent" && $watching_parent) {
- return LJ::S2::Link( "$LJ::SITEROOT/manage/subscriptions/comments?journal=$u->{'user'}&amp;talkid=$dtalkid",
+ return LJ::S2::Link( "$LJ::SITEROOT/manage/tracking/comments?journal=$u->{'user'}&amp;talkid=$dtalkid",
$ctx->[S2::PROPS]->{"text_multiform_opt_track"},
LJ::S2::Image_std( 'untrack' ), %btn_params );
}
@@ -3901,7 +3901,7 @@ sub _Entry__get_link
arg1 => $this->{itemid},
);

- return LJ::S2::Link( "$LJ::SITEROOT/manage/subscriptions/entry?journal=$journal&amp;itemid=$this->{'itemid'}",
+ return LJ::S2::Link( "$LJ::SITEROOT/manage/tracking/entry?journal=$journal&amp;itemid=$this->{'itemid'}",
$ctx->[S2::PROPS]->{"text_watch_comments"},
LJ::S2::Image_std( 'track' ),
'lj_journalid' => $journalu->id,
@@ -3933,7 +3933,7 @@ sub _Entry__get_link
subid => $subscr->id,
action => 'delsub' );

- return LJ::S2::Link( "$LJ::SITEROOT/manage/subscriptions/entry?journal=$journal&amp;itemid=$this->{'itemid'}",
+ return LJ::S2::Link( "$LJ::SITEROOT/manage/tracking/entry?journal=$journal&amp;itemid=$this->{'itemid'}",
$ctx->[S2::PROPS]->{"text_unwatch_comments"},
LJ::S2::Image_std( 'untrack' ),
'lj_journalid' => $journalu->id,
diff -r 4cf824f91dc2 -r 61e82aece0c1 cgi-bin/LJ/Talk.pm
--- a/cgi-bin/LJ/Talk.pm Mon May 02 21:13:34 2011 +0800
+++ b/cgi-bin/LJ/Talk.pm Tue May 03 11:18:42 2011 +0800
@@ -166,7 +166,7 @@ sub link_bar
if ($remote && $remote->can_use_esn) {
my $img_key = $remote->has_subscription(journal => $u, event => "JournalNewComment", arg1 => $itemid, require_active => 1) ?
"track_active" : "track";
- push @linkele, $mlink->("$LJ::SITEROOT/manage/subscriptions/entry?${jargent}itemid=$itemid", $img_key);
+ push @linkele, $mlink->("$LJ::SITEROOT/manage/tracking/entry?${jargent}itemid=$itemid", $img_key);
}


diff -r 4cf824f91dc2 -r 61e82aece0c1 cgi-bin/LJ/Widget/FriendUpdates.pm
--- a/cgi-bin/LJ/Widget/FriendUpdates.pm Mon May 02 21:13:34 2011 +0800
+++ b/cgi-bin/LJ/Widget/FriendUpdates.pm Tue May 03 11:18:42 2011 +0800
@@ -47,7 +47,7 @@ sub render_body {

unless (@notifications) {
$ret .= $class->ml('widget.friendupdates.noupdates');
- $ret .= "<p class='detail'>" . $class->ml('widget.friendupdates.noupdates.setup', {'aopts' => "href='$LJ::SITEROOT/manage/subscriptions/'"}) . "</p>";
+ $ret .= "<p class='detail'>" . $class->ml('widget.friendupdates.noupdates.setup', {'aopts' => "href='$LJ::SITEROOT/manage/settings/?cat=notifications'"}) . "</p>";
return $ret;
}

diff -r 4cf824f91dc2 -r 61e82aece0c1 cgi-bin/redirect.dat
--- a/cgi-bin/redirect.dat Mon May 02 21:13:34 2011 +0800
+++ b/cgi-bin/redirect.dat Tue May 03 11:18:42 2011 +0800
@@ -39,9 +39,9 @@
/manage/comments /manage/settings/?cat=privacy
/manage/comments/ /manage/settings/?cat=privacy
/manage/comments/index.bml /manage/settings/?cat=privacy
-/manage/subscriptions /manage/settings/?cat=notifications
-/manage/subscriptions/ /manage/settings/?cat=notifications
-/manage/subscriptions/index.bml /manage/settings/?cat=notifications
+/manage/subscriptions /manage/subscriptions/filters
+/manage/subscriptions/ /manage/subscriptions/filters
+/manage/subscriptions/index.bml /manage/subscriptions/filters
/mobile/friends.bml /mobile/read
/misc/import /tools/importer
/misc/import.bml /tools/importer
diff -r 4cf824f91dc2 -r 61e82aece0c1 cgi-bin/weblib.pl
--- a/cgi-bin/weblib.pl Mon May 02 21:13:34 2011 +0800
+++ b/cgi-bin/weblib.pl Tue May 03 11:18:42 2011 +0800
@@ -2757,7 +2757,7 @@ sub control_strip
$links{'view_friends_page'} = "<a href='" . $remote->journal_base . "/read'>$BML::ML{'web.controlstrip.links.viewreadingpage'}</a>";
$links{'add_friend'} = "<a href='$LJ::SITEROOT/manage/circle/add?user=$journal->{user}'>$BML::ML{'web.controlstrip.links.addtocircle'}</a>";
$links{'edit_friend'} = "<a href='$LJ::SITEROOT/manage/circle/add?user=$journal->{user}'>$BML::ML{'web.controlstrip.links.modifycircle'}</a>";
- $links{'track_user'} = "<a href='$LJ::SITEROOT/manage/subscriptions/user?journal=$journal->{user}'>$BML::ML{'web.controlstrip.links.trackuser'}</a>";
+ $links{'track_user'} = "<a href='$LJ::SITEROOT/manage/tracking/user?journal=$journal->{user}'>$BML::ML{'web.controlstrip.links.trackuser'}</a>";
if ($journal->is_syndicated ) {
$links{'add_friend'} = "<a href='$LJ::SITEROOT/manage/circle/add?user=$journal->{user}&action=subscribe'>$BML::ML{'web.controlstrip.links.addfeed'}</a>";
$links{'remove_friend'} = "<a href='$LJ::SITEROOT/manage/circle/add?user=$journal->{user}&action=remove'>$BML::ML{'web.controlstrip.links.removefeed'}</a>";
@@ -2772,7 +2772,7 @@ sub control_strip
$links{'edit_community_profile'} = "<a href='$LJ::SITEROOT/manage/profile/?authas=$journal->{user}'>$BML::ML{'web.controlstrip.links.editcommprofile'}</a>";
$links{'edit_community_invites'} = "<a href='$LJ::SITEROOT/community/sentinvites?authas=$journal->{user}'>$BML::ML{'web.controlstrip.links.managecomminvites'}</a>";
$links{'edit_community_members'} = "<a href='$LJ::SITEROOT/community/members?authas=$journal->{user}'>$BML::ML{'web.controlstrip.links.editcommmembers'}</a>";
- $links{'track_community'} = "<a href='$LJ::SITEROOT/manage/subscriptions/user?journal=$journal->{user}'>$BML::ML{'web.controlstrip.links.trackcomm'}</a>";
+ $links{'track_community'} = "<a href='$LJ::SITEROOT/manage/tracking/user?journal=$journal->{user}'>$BML::ML{'web.controlstrip.links.trackcomm'}</a>";
$links{'queue'} = "<a href='$LJ::SITEROOT/community/moderate?authas=$journal->{user}'>$BML::ML{'web.controlstrip.links.queue'}</a>";
}
}
@@ -3276,7 +3276,7 @@ sub subscribe_interface {
if ($post_to_settings_page) {
$ret .= "<form method='POST' action='$LJ::SITEROOT/manage/settings/?cat=notifications'>$formauth";
} elsif (!$settings_page) {
- $ret .= "<form method='POST' action='$LJ::SITEROOT/manage/subscriptions/$getextra'>$formauth";
+ $ret .= "<form method='POST' action='$LJ::SITEROOT/manage/tracking/$getextra'>$formauth";
}

my $events_table = $settings_page ? '<table class="Subscribe" style="clear: none;" cellpadding="0" cellspacing="0">' : '<table class="Subscribe" cellpadding="0" cellspacing="0">';
diff -r 4cf824f91dc2 -r 61e82aece0c1 htdocs/community/manage.bml
--- a/htdocs/community/manage.bml Mon May 02 21:13:34 2011 +0800
+++ b/htdocs/community/manage.bml Tue May 03 11:18:42 2011 +0800
@@ -135,7 +135,7 @@ body<=
$ret .= BML::ml('Actionlink', {
'link'=>"<a href='/manage/tags?authas=$user'>$ML{'.commlist.tags'}</a>"}) . "&nbsp;&nbsp;";
$ret .= BML::ml('Actionlink', {
- 'link'=>"<a href='/manage/subscriptions/user?journal=$user'>$ML{'.commlist.tracking'}</a>"}) . "&nbsp;&nbsp;";
+ 'link'=>"<a href='/manage/tracking/user?journal=$user'>$ML{'.commlist.tracking'}</a>"}) . "&nbsp;&nbsp;";
}
$ret .= "</td><td align='center'>";
if ($mods{$id}) {
@@ -175,7 +175,7 @@ body<=
$ret .= "<div class='columns-2-left'>\n";
# form for setting email option
$ret .= "<?h1 $ML{'.joinmail.title'} h1?>\n";
- $ret .= "<?p " . BML::ml('.joinmail.body2', { aopts=>"href='$LJ::SITEROOT/manage/subscriptions/'" }). " p?>\n";
+ $ret .= "<?p " . BML::ml('.joinmail.body2', { aopts=>"href='$LJ::SITEROOT/manage/settings/?cat=notifications'" }). " p?>\n";
$ret .= "<form method='post' action='manage'>\n";
$ret .= LJ::form_auth();
# options for getting moderation emails
diff -r 4cf824f91dc2 -r 61e82aece0c1 htdocs/inbox/index.bml
--- a/htdocs/inbox/index.bml Mon May 02 21:13:34 2011 +0800
+++ b/htdocs/inbox/index.bml Tue May 03 11:18:42 2011 +0800
@@ -149,7 +149,7 @@ body<=
<td id="table_inbox_messages" valign="top" style="padding-left: 10px; width: 100%;">
<div class="inbox_newitems pkg">
<span class="esnlinks" style="float: left"><a href="$LJ::SITEROOT/inbox/?page=$page$viewarg$itemidarg" id="RefreshLink"><?_ml inbox.refresh _ml?></a> |
- <a href="$LJ::SITEROOT/manage/subscriptions/"><?_ml inbox.manage_settings _ml?></a></span>
+ <a href="$LJ::SITEROOT/manage/settings/?cat=notifications"><?_ml inbox.manage_settings _ml?></a></span>
</div>

};
@@ -189,7 +189,7 @@ body<=
$body .= qq{
<div class="inbox_newitems pkg">
<span class="esnlinks" style="float: left"><a href="$LJ::SITEROOT/inbox/?page=$page$viewarg$itemidarg"><?_ml inbox.refresh _ml?></a> |
- <a href="$LJ::SITEROOT/manage/subscriptions/"><?_ml inbox.manage_settings _ml?></a></span>
+ <a href="$LJ::SITEROOT/manage/settings/?cat=notifications"><?_ml inbox.manage_settings _ml?></a></span>
</div>
} if $itemcount > 10;

diff -r 4cf824f91dc2 -r 61e82aece0c1 htdocs/manage/index.bml
--- a/htdocs/manage/index.bml Mon May 02 21:13:34 2011 +0800
+++ b/htdocs/manage/index.bml Tue May 03 11:18:42 2011 +0800
@@ -147,7 +147,7 @@ _code?>
my $remote = LJ::get_remote();

if ($remote && $remote->can_use_esn) {
- return '<li><a href="/manage/subscriptions/" title="<?_ml .manage.notifications.about _ml?>"><?_ml .manage.notifications _ml?></a></li>';
+ return '<li><a href="/manage/settings/?cat=notifications" title="<?_ml .manage.notifications.about _ml?>"><?_ml .manage.notifications _ml?></a></li>';
} else {
return '';
}
diff -r 4cf824f91dc2 -r 61e82aece0c1 htdocs/manage/subscriptions/comments.bml
--- a/htdocs/manage/subscriptions/comments.bml Mon May 02 21:13:34 2011 +0800
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,120 +0,0 @@
-<?_c
-# This code was forked from the LiveJournal project owned and operated
-# by Live Journal, Inc. The code has been modified and expanded by
-# Dreamwidth Studios, LLC. These files were originally licensed under
-# the terms of the license supplied by Live Journal, Inc, which can
-# currently be found at:
-#
-# http://code.livejournal.org/trac/livejournal/browser/trunk/LICENSE-LiveJournal.txt
-#
-# In accordance with the original license, this code and all its
-# modifications are provided under the GNU General Public License.
-# A copy of that license can be found in the LICENSE file included as
-# part of this distribution.
-_c?>
-<?page
-body<=
-<?_code
-{
- use strict;
- use vars qw (%POST %GET $body $title $headextra @errors);
- use Carp qw(croak);
- use LJ::Subscription;
- use LJ::NotificationMethod;
- use LJ::Event;
- use LJ::Comment;
-
- $title = 'Manage Message Settings';
-
- return "Not ready" unless LJ::is_enabled('esn');
-
- BML::decl_params(
- lj_form_auth => qr/./,
- journal => 'word',
- dtalkid => 'digits',
- ditemid => 'digits',
- talkid => 'digits',
- itemid => 'digits',
- );
-
- my $remote = LJ::get_remote();
- return "<?needlogin?>" unless $remote;
-
- my $ditemid = $POST{'itemid'} || $GET{'itemid'} || $POST{'ditemid'} || $GET{'ditemid'};
- my $dtalkid = $POST{'talkid'} || $GET{'talkid'} || $POST{'dtalkid'} || $POST{'dtalkid'};
- my $journal = $POST{'journal'} || $GET{'journal'};
-
- return LJ::error_list( "No journal specified" ) unless $journal;
- $journal = LJ::load_user($journal) or return LJ::error_list("Invalid journal '$journal'");
-
- return LJ::error_list("No talkid specified") unless $dtalkid;
-
- my $comment = LJ::Comment->new($journal, dtalkid => $dtalkid);
-
- return LJ::error_list("Invalid comment") unless $comment && $comment->visible_to($remote);
- return LJ::error_list("This comment has been deleted.") if $comment->is_deleted;
-
- my $entry = $comment->entry;
- $ditemid ||= $entry->ditemid;
-
- my $thread_sub = LJ::Subscription::Pending->new(
- $remote,
- journal => $journal,
- event => 'JournalNewComment',
- arg2 => $comment && $comment->jtalkid,
- default_selected => 1,
- flags => LJ::Subscription::TRACKING,
- );
-
- my $can_watch = $thread_sub->available_for_user;
-
- push @errors, $ML{'.error.threads'}
- unless $can_watch;
-
- my @pending = $thread_sub;
-
- push @pending, LJ::Subscription::Pending->new(
- $remote,
- journal => $journal,
- event => 'JournalNewComment',
- arg1 => $ditemid,
- # select by default only if they can't watch the subthread above
- default_selected => $can_watch ? 0 : 1,
- flags => LJ::Subscription::TRACKING,
- );
-
- push @pending,
- LJ::Subscription::Pending->new(
- $remote,
- event => "JournalNewComment",
- journal => $journal,
- flags => LJ::Subscription::TRACKING,
- ) if $remote->can_track_all_community_comments ( $journal );
-
- my $categories = [ { 'Track Comments' => [ @pending ] } ];
-
- my $referer = BML::get_client_header('Referer');
- my ( $style ) = ( $referer =~ /\b(style=\w+)/ );
- $style = LJ::viewing_style_args( split( /=/, $style ) );
-
- return LJ::subscribe_interface(
- $remote,
- categories => $categories,
- journal => $journal,
- ret_url => ($can_watch ? $comment->url( $style ) : $entry->url . "?$style" ),
- default_selected_notifications => ['LJ::NotificationMethod::Email'],
- post_to_settings_page => 1,
- );
-
-}
-_code?>
-<=body
-title=><?_code return $title; _code?>
-head<=
-<style type='text/css'>
-</style>
-<?_code return $headextra; _code?>
-<=head
-<=body
-page?>
-
diff -r 4cf824f91dc2 -r 61e82aece0c1 htdocs/manage/subscriptions/comments.bml.text
--- a/htdocs/manage/subscriptions/comments.bml.text Mon May 02 21:13:34 2011 +0800
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,3 +0,0 @@
-;; -*- coding: utf-8 -*-
-.error.threads=Your account level doesn't allow watching threads, but you can watch the entire entry by clicking below.
-
diff -r 4cf824f91dc2 -r 61e82aece0c1 htdocs/manage/subscriptions/entry.bml
--- a/htdocs/manage/subscriptions/entry.bml Mon May 02 21:13:34 2011 +0800
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,122 +0,0 @@
-<?_c
-# This code was forked from the LiveJournal project owned and operated
-# by Live Journal, Inc. The code has been modified and expanded by
-# Dreamwidth Studios, LLC. These files were originally licensed under
-# the terms of the license supplied by Live Journal, Inc, which can
-# currently be found at:
-#
-# http://code.livejournal.org/trac/livejournal/browser/trunk/LICENSE-LiveJournal.txt
-#
-# In accordance with the original license, this code and all its
-# modifications are provided under the GNU General Public License.
-# A copy of that license can be found in the LICENSE file included as
-# part of this distribution.
-_c?>
-<?page
-body<=
-<?_code
-{
- use strict;
- use vars qw (%POST %GET $body $title $headextra);
- use Carp qw(croak);
- use LJ::NotificationMethod;
- use LJ::Event;
-
- $title = 'Manage Message Settings';
-
- return "Not ready" unless LJ::is_enabled('esn');
-
- BML::decl_params(
- lj_form_auth => qr/./,
- journal => 'word',
- ditemid => 'digits',
- itemid => 'digits',
- );
-
- my $remote = LJ::get_remote();
- return "<?needlogin?>" unless $remote;
-
- my $ditemid = $POST{'itemid'} || $GET{'itemid'} || $POST{'ditemid'} || $GET{'ditemid'};
- my $journal = $POST{'journal'} || $GET{'journal'};
- my $ntypeid = int($POST{'ntypeid'});
-
- return LJ::error_list( "No journal specified" ) unless $journal;
- $journal = LJ::load_user($journal) or return LJ::error_list("Invalid journal '$journal'");
-
- return LJ::error_list("No entry specified") unless $ditemid;
-
- my $entry = LJ::Entry->new($journal, ditemid => $ditemid);
-
- return LJ::error_list("Invalid entry") unless $entry && $entry->valid;
- return LJ::error_list("You are not authorized to subscribe to this entry.") unless $entry->visible_to($remote);
-
- my $cat_title = 'Track Entry';
- my $categories =
- [
- { $cat_title =>
- [
- LJ::Subscription::Pending->new( $remote,
- event => "JournalNewComment",
- arg1 => $ditemid,
- journal => $journal,
- default_selected => 1,
- flags => LJ::Subscription::TRACKING,
- ),
-
- LJ::Subscription::Pending->new( $remote,
- event => "JournalNewComment::TopLevel",
- arg1 => $ditemid,
- journal => $journal,
- default_selected => 0,
- flags => LJ::Subscription::TRACKING,
- ),
- ],
- }
- ];
-
- push @{ @$categories[0]->{$cat_title} },
- LJ::Subscription::Pending->new( $remote,
- event => "JournalNewComment",
- journal => $journal,
- flags => LJ::Subscription::TRACKING,
- ) if $remote->can_track_all_community_comments( $journal );
-
- push @{ @$categories[0]->{$cat_title} },
- LJ::Subscription::Pending->new( $remote,
- event => "JournalNewEntry",
- arg1 => '?',
- journal => $journal,
- entry => $entry,
- flags => LJ::Subscription::TRACKING,
- ),
- LJ::Subscription::Pending->new( $remote,
- event => "JournalNewEntry",
- journal => $journal,
- flags => LJ::Subscription::TRACKING,
- );
-
- my $referer = BML::get_client_header('Referer');
- my ( $style ) = ( $referer =~ /\b(style=\w+)/ );
- $style = LJ::viewing_style_args( split( /=/, $style ) );
-
- $body .= LJ::subscribe_interface( $remote,
- journal => $journal,
- categories => $categories,
- ret_url => $entry->url . "?$style",
- default_selected_notifications => ['LJ::NotificationMethod::Email'],
- post_to_settings_page => 1,
- );
-
- return $body;
-}
-_code?>
-<=body
-title=><?_code return $title; _code?>
-head<=
-<style type='text/css'>
-</style>
-<?_code return $headextra; _code?>
-<=head
-<=body
-page?>
-
diff -r 4cf824f91dc2 -r 61e82aece0c1 htdocs/manage/subscriptions/user.bml
--- a/htdocs/manage/subscriptions/user.bml Mon May 02 21:13:34 2011 +0800
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,121 +0,0 @@
-<?_c
-# This code was forked from the LiveJournal project owned and operated
-# by Live Journal, Inc. The code has been modified and expanded by
-# Dreamwidth Studios, LLC. These files were originally licensed under
-# the terms of the license supplied by Live Journal, Inc, which can
-# currently be found at:
-#
-# http://code.livejournal.org/trac/livejournal/browser/trunk/LICENSE-LiveJournal.txt
-#
-# In accordance with the original license, this code and all its
-# modifications are provided under the GNU General Public License.
-# A copy of that license can be found in the LICENSE file included as
-# part of this distribution.
-_c?>
-<?page
-body<=
-<?_code
-{
- use strict;
- use vars qw (%POST %GET $body $title $headextra);
- use Carp qw(croak);
- use LJ::NotificationMethod;
- use LJ::Event;
-
- $title = 'Manage Message Settings';
-
- return "Not ready" unless LJ::is_enabled('esn');
-
- BML::decl_params(
- lj_form_auth => qr/./,
- journal => 'word',
- _default => qr/./,
- );
-
- my $remote = LJ::get_remote();
- return "<?needlogin?>" unless $remote;
-
- my $journal = LJ::load_user($GET{journal}) or return LJ::bad_input("No journal specified");
-
- return BML::redirect("$LJ::SITEROOT/manage/subscriptions/") if $remote->equals( $journal );
-
- # what classes to display on this page
- my $cat_title = 'Track User';
- my $categories =
- [
- { $cat_title =>
- [
- LJ::Subscription::Pending->new( $remote,
- event => "JournalNewEntry",
- arg1 => '?',
- journal => $journal,
- flags => LJ::Subscription::TRACKING,
- ),
- LJ::Subscription::Pending->new( $remote,
- event => "JournalNewEntry",
- journal => $journal,
- flags => LJ::Subscription::TRACKING,
- ),
- ]
- },
- ];
-
- push @{ @$categories[0]->{$cat_title} },
- LJ::Subscription::Pending->new( $remote,
- event => "UserExpunged",
- journal => $journal,
- flags => LJ::Subscription::TRACKING,
- ) unless LJ::User->is_protected_username( $journal->user );
-
- push @{ @$categories[0]->{$cat_title} },
- LJ::Subscription::Pending->new( $remote,
- event => "JournalNewComment",
- journal => $journal,
- flags => LJ::Subscription::TRACKING,
- ) if $remote->can_track_all_community_comments( $journal );
-
- push @{ @$categories[0]->{$cat_title} },
- LJ::Subscription::Pending->new( $remote,
- event => "NewUserpic",
- journal => $journal,
- flags => LJ::Subscription::TRACKING,
- disabled => ! $remote->can_track_new_userpic,
- ),
- LJ::Subscription::Pending->new( $remote,
- event => "Birthday",
- journal => $journal,
- flags => LJ::Subscription::TRACKING,
- );
-
- # validate referer for ret_url
- my $referer = BML::get_client_header('Referer');
- $referer = $LJ::SITEROOT . $referer if $referer =~ /^\//;
- if ( DW::Controller::validate_redirect_url( $referer ) ) {
- # validate args
- my ( $url, $args ) = ( $referer =~ /^(.*)\?(.*)$/ );
- if ( $url && $args ) {
- my %args = map { split( /=/, $_ ) } split( /&/, $args );
- $args = LJ::viewing_style_args( %args );
- $referer = $args ? "$url?$args" : $url;
- }
- } else {
- $referer = undef; # invalid redirect
- }
-
- return LJ::subscribe_interface( $remote,
- categories => $categories,
- journal => $journal,
- ret_url => $referer,
- post_to_settings_page => 1,
- );
-
-}
-_code?>
-<=body
-title=><?_code return $title; _code?>
-head<=
-<?_code return $headextra; _code?>
-<=head
-<=body
-page?>
-
diff -r 4cf824f91dc2 -r 61e82aece0c1 htdocs/manage/tracking/comments.bml
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/htdocs/manage/tracking/comments.bml Tue May 03 11:18:42 2011 +0800
@@ -0,0 +1,120 @@
+<?_c
+# This code was forked from the LiveJournal project owned and operated
+# by Live Journal, Inc. The code has been modified and expanded by
+# Dreamwidth Studios, LLC. These files were originally licensed under
+# the terms of the license supplied by Live Journal, Inc, which can
+# currently be found at:
+#
+# http://code.livejournal.org/trac/livejournal/browser/trunk/LICENSE-LiveJournal.txt
+#
+# In accordance with the original license, this code and all its
+# modifications are provided under the GNU General Public License.
+# A copy of that license can be found in the LICENSE file included as
+# part of this distribution.
+_c?>
+<?page
+body<=
+<?_code
+{
+ use strict;
+ use vars qw (%POST %GET $body $title $headextra @errors);
+ use Carp qw(croak);
+ use LJ::Subscription;
+ use LJ::NotificationMethod;
+ use LJ::Event;
+ use LJ::Comment;
+
+ $title = 'Manage Message Settings';
+
+ return "Not ready" unless LJ::is_enabled('esn');
+
+ BML::decl_params(
+ lj_form_auth => qr/./,
+ journal => 'word',
+ dtalkid => 'digits',
+ ditemid => 'digits',
+ talkid => 'digits',
+ itemid => 'digits',
+ );
+
+ my $remote = LJ::get_remote();
+ return "<?needlogin?>" unless $remote;
+
+ my $ditemid = $POST{'itemid'} || $GET{'itemid'} || $POST{'ditemid'} || $GET{'ditemid'};
+ my $dtalkid = $POST{'talkid'} || $GET{'talkid'} || $POST{'dtalkid'} || $POST{'dtalkid'};
+ my $journal = $POST{'journal'} || $GET{'journal'};
+
+ return LJ::error_list( "No journal specified" ) unless $journal;
+ $journal = LJ::load_user($journal) or return LJ::error_list("Invalid journal '$journal'");
+
+ return LJ::error_list("No talkid specified") unless $dtalkid;
+
+ my $comment = LJ::Comment->new($journal, dtalkid => $dtalkid);
+
+ return LJ::error_list("Invalid comment") unless $comment && $comment->visible_to($remote);
+ return LJ::error_list("This comment has been deleted.") if $comment->is_deleted;
+
+ my $entry = $comment->entry;
+ $ditemid ||= $entry->ditemid;
+
+ my $thread_sub = LJ::Subscription::Pending->new(
+ $remote,
+ journal => $journal,
+ event => 'JournalNewComment',
+ arg2 => $comment && $comment->jtalkid,
+ default_selected => 1,
+ flags => LJ::Subscription::TRACKING,
+ );
+
+ my $can_watch = $thread_sub->available_for_user;
+
+ push @errors, $ML{'.error.threads'}
+ unless $can_watch;
+
+ my @pending = $thread_sub;
+
+ push @pending, LJ::Subscription::Pending->new(
+ $remote,
+ journal => $journal,
+ event => 'JournalNewComment',
+ arg1 => $ditemid,
+ # select by default only if they can't watch the subthread above
+ default_selected => $can_watch ? 0 : 1,
+ flags => LJ::Subscription::TRACKING,
+ );
+
+ push @pending,
+ LJ::Subscription::Pending->new(
+ $remote,
+ event => "JournalNewComment",
+ journal => $journal,
+ flags => LJ::Subscription::TRACKING,
+ ) if $remote->can_track_all_community_comments ( $journal );
+
+ my $categories = [ { 'Track Comments' => [ @pending ] } ];
+
+ my $referer = BML::get_client_header('Referer');
+ my ( $style ) = ( $referer =~ /\b(style=\w+)/ );
+ $style = LJ::viewing_style_args( split( /=/, $style ) );
+
+ return LJ::subscribe_interface(
+ $remote,
+ categories => $categories,
+ journal => $journal,
+ ret_url => ($can_watch ? $comment->url( $style ) : $entry->url . "?$style" ),
+ default_selected_notifications => ['LJ::NotificationMethod::Email'],
+ post_to_settings_page => 1,
+ );
+
+}
+_code?>
+<=body
+title=><?_code return $title; _code?>
+head<=
+<style type='text/css'>
+</style>
+<?_code return $headextra; _code?>
+<=head
+<=body
+page?>
+
diff -r 4cf824f91dc2 -r 61e82aece0c1 htdocs/manage/tracking/comments.bml.text
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/htdocs/manage/tracking/comments.bml.text Tue May 03 11:18:42 2011 +0800
@@ -0,0 +1,3 @@
+;; -*- coding: utf-8 -*-
+.error.threads=Your account level doesn't allow watching threads, but you can watch the entire entry by clicking below.
+
diff -r 4cf824f91dc2 -r 61e82aece0c1 htdocs/manage/tracking/entry.bml
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/htdocs/manage/tracking/entry.bml Tue May 03 11:18:42 2011 +0800
@@ -0,0 +1,122 @@
+<?_c
+# This code was forked from the LiveJournal project owned and operated
+# by Live Journal, Inc. The code has been modified and expanded by
+# Dreamwidth Studios, LLC. These files were originally licensed under
+# the terms of the license supplied by Live Journal, Inc, which can
+# currently be found at:
+#
+# http://code.livejournal.org/trac/livejournal/browser/trunk/LICENSE-LiveJournal.txt
+#
+# In accordance with the original license, this code and all its
+# modifications are provided under the GNU General Public License.
+# A copy of that license can be found in the LICENSE file included as
+# part of this distribution.
+_c?>
+<?page
+body<=
+<?_code
+{
+ use strict;
+ use vars qw (%POST %GET $body $title $headextra);
+ use Carp qw(croak);
+ use LJ::NotificationMethod;
+ use LJ::Event;
+
+ $title = 'Manage Message Settings';
+
+ return "Not ready" unless LJ::is_enabled('esn');
+
+ BML::decl_params(
+ lj_form_auth => qr/./,
+ journal => 'word',
+ ditemid => 'digits',
+ itemid => 'digits',
+ );
+
+ my $remote = LJ::get_remote();
+ return "<?needlogin?>" unless $remote;
+
+ my $ditemid = $POST{'itemid'} || $GET{'itemid'} || $POST{'ditemid'} || $GET{'ditemid'};
+ my $journal = $POST{'journal'} || $GET{'journal'};
+ my $ntypeid = int($POST{'ntypeid'});
+
+ return LJ::error_list( "No journal specified" ) unless $journal;
+ $journal = LJ::load_user($journal) or return LJ::error_list("Invalid journal '$journal'");
+
+ return LJ::error_list("No entry specified") unless $ditemid;
+
+ my $entry = LJ::Entry->new($journal, ditemid => $ditemid);
+
+ return LJ::error_list("Invalid entry") unless $entry && $entry->valid;
+ return LJ::error_list("You are not authorized to subscribe to this entry.") unless $entry->visible_to($remote);
+
+ my $cat_title = 'Track Entry';
+ my $categories =
+ [
+ { $cat_title =>
+ [
+ LJ::Subscription::Pending->new( $remote,
+ event => "JournalNewComment",
+ arg1 => $ditemid,
+ journal => $journal,
+ default_selected => 1,
+ flags => LJ::Subscription::TRACKING,
+ ),
+
+ LJ::Subscription::Pending->new( $remote,
+ event => "JournalNewComment::TopLevel",
+ arg1 => $ditemid,
+ journal => $journal,
+ default_selected => 0,
+ flags => LJ::Subscription::TRACKING,
+ ),
+ ],
+ }
+ ];
+
+ push @{ @$categories[0]->{$cat_title} },
+ LJ::Subscription::Pending->new( $remote,
+ event => "JournalNewComment",
+ journal => $journal,
+ flags => LJ::Subscription::TRACKING,
+ ) if $remote->can_track_all_community_comments( $journal );
+
+ push @{ @$categories[0]->{$cat_title} },
+ LJ::Subscription::Pending->new( $remote,
+ event => "JournalNewEntry",
+ arg1 => '?',
+ journal => $journal,
+ entry => $entry,
+ flags => LJ::Subscription::TRACKING,
+ ),
+ LJ::Subscription::Pending->new( $remote,
+ event => "JournalNewEntry",
+ journal => $journal,
+ flags => LJ::Subscription::TRACKING,
+ );
+
+ my $referer = BML::get_client_header('Referer');
+ my ( $style ) = ( $referer =~ /\b(style=\w+)/ );
+ $style = LJ::viewing_style_args( split( /=/, $style ) );
+
+ $body .= LJ::subscribe_interface( $remote,
+ journal => $journal,
+ categories => $categories,
+ ret_url => $entry->url . "?$style",
+ default_selected_notifications => ['LJ::NotificationMethod::Email'],
+ post_to_settings_page => 1,
+ );
+
+ return $body;
+}
+_code?>
+<=body
+title=><?_code return $title; _code?>
+head<=
+<style type='text/css'>
+</style>
+<?_code return $headextra; _code?>
+<=head
+<=body
+page?>
+
diff -r 4cf824f91dc2 -r 61e82aece0c1 htdocs/manage/tracking/user.bml
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/htdocs/manage/tracking/user.bml Tue May 03 11:18:42 2011 +0800
@@ -0,0 +1,121 @@
+<?_c
+# This code was forked from the LiveJournal project owned and operated
+# by Live Journal, Inc. The code has been modified and expanded by
+# Dreamwidth Studios, LLC. These files were originally licensed under
+# the terms of the license supplied by Live Journal, Inc, which can
+# currently be found at:
+#
+# http://code.livejournal.org/trac/livejournal/browser/trunk/LICENSE-LiveJournal.txt
+#
+# In accordance with the original license, this code and all its
+# modifications are provided under the GNU General Public License.
+# A copy of that license can be found in the LICENSE file included as
+# part of this distribution.
+_c?>
+<?page
+body<=
+<?_code
+{
+ use strict;
+ use vars qw (%POST %GET $body $title $headextra);
+ use Carp qw(croak);
+ use LJ::NotificationMethod;
+ use LJ::Event;
+
+ $title = 'Manage Message Settings';
+
+ return "Not ready" unless LJ::is_enabled('esn');
+
+ BML::decl_params(
+ lj_form_auth => qr/./,
+ journal => 'word',
+ _default => qr/./,
+ );
+
+ my $remote = LJ::get_remote();
+ return "<?needlogin?>" unless $remote;
+
+ my $journal = LJ::load_user($GET{journal}) or return LJ::bad_input("No journal specified");
+
+ return BML::redirect("$LJ::SITEROOT/manage/settings/?cat=notifications") if $remote->equals( $journal );
+
+ # what classes to display on this page
+ my $cat_title = 'Track User';
+ my $categories =
+ [
+ { $cat_title =>
+ [
+ LJ::Subscription::Pending->new( $remote,
+ event => "JournalNewEntry",
+ arg1 => '?',
+ journal => $journal,
+ flags => LJ::Subscription::TRACKING,
+ ),
+ LJ::Subscription::Pending->new( $remote,
+ event => "JournalNewEntry",
+ journal => $journal,
+ flags => LJ::Subscription::TRACKING,
+ ),
+ ]
+ },
+ ];
+
+ push @{ @$categories[0]->{$cat_title} },
+ LJ::Subscription::Pending->new( $remote,
+ event => "UserExpunged",
+ journal => $journal,
+ flags => LJ::Subscription::TRACKING,
+ ) unless LJ::User->is_protected_username( $journal->user );
+
+ push @{ @$categories[0]->{$cat_title} },
+ LJ::Subscription::Pending->new( $remote,
+ event => "JournalNewComment",
+ journal => $journal,
+ flags => LJ::Subscription::TRACKING,
+ ) if $remote->can_track_all_community_comments( $journal );
+
+ push @{ @$categories[0]->{$cat_title} },
+ LJ::Subscription::Pending->new( $remote,
+ event => "NewUserpic",
+ journal => $journal,
+ flags => LJ::Subscription::TRACKING,
+ disabled => ! $remote->can_track_new_userpic,
+ ),
+ LJ::Subscription::Pending->new( $remote,
+ event => "Birthday",
+ journal => $journal,
+ flags => LJ::Subscription::TRACKING,
+ );
+
+ # validate referer for ret_url
+ my $referer = BML::get_client_header('Referer');
+ $referer = $LJ::SITEROOT . $referer if $referer =~ /^\//;
+ if ( DW::Controller::validate_redirect_url( $referer ) ) {
+ # validate args
+ my ( $url, $args ) = ( $referer =~ /^(.*)\?(.*)$/ );
+ if ( $url && $args ) {
+ my %args = map { split( /=/, $_ ) } split( /&/, $args );
+ $args = LJ::viewing_style_args( %args );
+ $referer = $args ? "$url?$args" : $url;
+ }
+ } else {
+ $referer = undef; # invalid redirect
+ }
+
+ return LJ::subscribe_interface( $remote,
+ categories => $categories,
+ journal => $journal,
+ ret_url => $referer,
+ post_to_settings_page => 1,
+ );
+
+}
+_code?>
+<=body
+title=><?_code return $title; _code?>
+head<=
+<?_code return $headextra; _code?>
+<=head
+<=body
+page?>
+
diff -r 4cf824f91dc2 -r 61e82aece0c1 htdocs/profile.bml
--- a/htdocs/profile.bml Mon May 02 21:13:34 2011 +0800
+++ b/htdocs/profile.bml Tue May 03 11:18:42 2011 +0800
@@ -149,7 +149,7 @@ body<=
$del_body .= "&nbsp;" . BML::ml( 'error.deleted.leavecomm', { aopts => "href='$LJ::SITEROOT/community/leave?comm=" . $u->user . "'" } ) if $u->is_community && $u->trusts_or_has_member( $remote );

$del_body .= " p?>";
- $del_body .= BML::ml( '.error.deleted.purgenotification', { aopts => "href='$LJ::SITEROOT/manage/subscriptions/user?journal=" . $u->user . "'" } )
+ $del_body .= BML::ml( '.error.deleted.purgenotification', { aopts => "href='$LJ::SITEROOT/manage/tracking/user?journal=" . $u->user . "'" } )
unless LJ::User->is_protected_username( $u->user );
return $del_body;
}
diff -r 4cf824f91dc2 -r 61e82aece0c1 htdocs/talkread.bml
--- a/htdocs/talkread.bml Mon May 02 21:13:34 2011 +0800
+++ b/htdocs/talkread.bml Tue May 03 11:18:42 2011 +0800
@@ -557,7 +557,7 @@ body<=
}
}

- my $track_url = "$LJ::SITEROOT/manage/subscriptions/comments?journal=$u->{'user'}&amp;talkid=$dtid";
+ my $track_url = "$LJ::SITEROOT/manage/tracking/comments?journal=$u->{'user'}&amp;talkid=$dtid";
$ret .= "<a href='$track_url'>" . LJ::img($track_img, '', {'align' => 'absmiddle'}) . "</a>";
}

Loading...