ssafronova (ssafronova) wrote in changelog,
ssafronova
ssafronova
changelog

[livejournal] r16492: LJSV-1035: Need to change text for 'Temp...

Committer: ssafronova
LJSV-1035: Need to change text for 'Temporarily banned as a bot' message
U   trunk/bin/upgrading/en.dat
U   trunk/cgi-bin/Apache/LiveJournal.pm
Modified: trunk/bin/upgrading/en.dat
===================================================================
--- trunk/bin/upgrading/en.dat	2010-04-01 17:10:55 UTC (rev 16491)
+++ trunk/bin/upgrading/en.dat	2010-04-02 04:53:11 UTC (rev 16492)
@@ -1296,6 +1296,16 @@
 
 error.badpassword=Incorrect Password.
 
+error.banned.bot.subject=Access Forbidden
+
+error.banned.bot.message<<
+This page is not available at this time, perhaps because you were hitting the site too quickly. Please make sure that you're
+following our <a href='http://www.livejournal.com/bots/'>Bot Policy</a>.
+<br>If you are not using an automated service of the type described at the page above, then you may have been shown this page in error.
+Please refresh the page and try again. If you are still blocked from using LiveJournal after refreshing the page, contact us at
+webmaster&#064;livejournal.com with the following information: [[uniq]] @ [[ip]].
+.
+
 error.code.comm_not_comm=Account is not a community
 
 error.code.comm_not_found=Community not found

Modified: trunk/cgi-bin/Apache/LiveJournal.pm
===================================================================
--- trunk/cgi-bin/Apache/LiveJournal.pm	2010-04-01 17:10:55 UTC (rev 16491)
+++ trunk/cgi-bin/Apache/LiveJournal.pm	2010-04-02 04:53:11 UTC (rev 16492)
@@ -235,15 +235,21 @@
     LJ::Request->status_line("403 Denied");
     LJ::Request->content_type("text/html");
     LJ::Request->send_http_header();
-    my $subject = $LJ::BLOCKED_BOT_SUBJECT || "403 Denied";
-    my $message = $LJ::BLOCKED_BOT_MESSAGE || "You don't have permission to view this page.";
 
+    my ($ip, $uniq);
     if ($LJ::BLOCKED_BOT_INFO) {
-        my $ip = LJ::get_remote_ip();
-        my $uniq = LJ::UniqCookie->current_uniq;
-        $message .= " $uniq @ $ip";
+        $ip = LJ::get_remote_ip();
+        $uniq = LJ::UniqCookie->current_uniq;
     }
 
+    my $subject = LJ::Lang::get_text(undef, 'error.banned.bot.subject') || $LJ::BLOCKED_BOT_SUBJECT || "403 Denied";
+    my $message = LJ::Lang::get_text(undef, 'error.banned.bot.message', undef, { ip => $ip, uniq => $uniq } );
+
+    unless ($message) {
+        $message = $LJ::BLOCKED_BOT_MESSAGE || "You don't have permission to view this page.";
+        $message .= " $uniq @ $ip" if $LJ::BLOCKED_BOT_INFO;
+    }
+
     LJ::Request->print("<h1>$subject</h1>$message");
     return LJ::Request::OK;
 }

Tags: dat, livejournal, pm, ssafronova
Subscribe

  • Post a new comment

    Error

    Anonymous comments are disabled in this journal

    default userpic

    Your reply will be screened

    Your IP address will be recorded 

  • 0 comments