Савинцев Егор 🚶 (savintsev_egor) wrote in changelog,
Савинцев Егор 🚶
savintsev_egor
changelog

[livejournal] r19652: LJSUP-9404: S2 Anchors

Committer: esavintcev
LJSUP-9404: S2 Anchors
U   trunk/bin/upgrading/s2layers/classic/layout.s2
Modified: trunk/bin/upgrading/s2layers/classic/layout.s2
===================================================================
--- trunk/bin/upgrading/s2layers/classic/layout.s2	2011-08-09 06:21:37 UTC (rev 19651)
+++ trunk/bin/upgrading/s2layers/classic/layout.s2	2011-08-09 06:25:09 UTC (rev 19652)
@@ -743,11 +743,10 @@
         print safe "$*text_max_comments";
     } else {
      if ($p.view == "entry") {
-            $p->print_reply_link({"target" => "topcomment", "linktext" => $*text_post_comment});
-            ###$p->print_reply_container({"target" => "topcomment"});
+            $p->print_reply_link({"target" => "topcomment", "linktext" => $*text_post_comment, "reply_url" => $.post_url+"#$*text_addcomment_id"});
      }
     else {
-        print safe "<a href=\"$.post_url\">"+($p.view == "friends" ? $*text_post_comment_friends : $*text_post_comment)+"</a>";
+        print safe "<a href=\"$.post_url#$*text_addcomment_id\">"+($p.view == "friends" ? $*text_post_comment_friends : $*text_post_comment)+"</a>";
     }
      }
 }
@@ -757,7 +756,7 @@
     if ($p.showspam) {
         print safe get_plural_phrase($.spam_counter, "text_read_spam_comments");
     } else {
-        print safe "<a href=\"$.read_spam_url\">" + get_plural_phrase($.spam_counter, "text_read_all_spam_comments") + "</a>";
+        print safe "<a href=\"$.read_spam_url#$*text_comments_id\">" + get_plural_phrase($.spam_counter, "text_read_all_spam_comments") + "</a>";
     }
 }
 
@@ -924,7 +923,7 @@
         }
 
         $this->print_multiform_start();
-        "<tr valign='top'><th class='headerbar' colspan='2'>Comments</th></tr>";
+        "<tr valign='top'><th class='headerbar' colspan='2' id='$*text_comments_id'>Comments</th></tr>";
         "<tr valign='top'><td style='background-color: $background'>&nbsp;</td><td style='width: 100%'>";
         if ($.comment_pages.total_subitems > 0) {
             $.comment_pages->print();
@@ -1133,9 +1132,9 @@
         "</td></tr>\n";
     }             
 
-    "<div align='center'><a href='$.entry.comments.read_url'>( Read Comments )</a></div>";
+    "<div align='center'>( <a href='$.entry.comments.read_url#$*text_comments_id'>" + get_plural_phrase($.entry.comments.count, "text_read_comments") + "</a> )</div>";
          print_ebox($.entry);
-     "<tr valign='top'><th class='headerbar' colspan='2'>Reply:</th></tr>";
+     "<tr valign='top'><th class='headerbar' colspan='2' id='$*text_addcomment_id'>$*text_post_comment:</th></tr>";
     "<tr valing='top'><td style='background-color: $background'>&nbsp;</td><td>";
     $.form->print();
     "</td></tr></table>";

Tags: livejournal, s2, savintsev_egor
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