anchor.diff:  register() ->
       header("echessd - Register new user", []) ++
           h1("echessd register form") ++
  -        "<div class=navig>[&nbsp;<a href='?goto=login'>Return to login form</a>&nbsp;]</div>"
  +        navig_links([{"?goto=login", "Return to login form"}]) ++
           "<form method=post>"
           "<input name=action type=hidden value=register>"
           "Login:    <input name=regusername type=text><br>"
  
positive.code: figure_(?b_knight) -> 9822;
  figure_(?b_pawn  ) -> 9823.
  
  navigation() ->
      Curr = echessd_session:get_val(section),
      "<div class=navig>[&nbsp;" ++
          string:join(
            lists:map(
              fun(Section) ->
                      Caption =
                          case Section of
                              ?SECTION_HOME -> "Home";
                              ?SECTION_USERS -> "Users";
                              _ -> Section
                          end,
                      "<a href='?goto=" ++ Section ++ "'>" ++
                          if Section == Curr ->
                                  "<b>" ++ Caption ++ "</b>";
                             true -> Caption
                          end ++ "</a>"
              end,
              [?SECTION_HOME, ?SECTION_USERS, ?SECTION_TEST]),
            "&nbsp;|&nbsp;") ++
          "&nbsp;|&nbsp;<a href='?action=exit'>Logout</a>"
          "&nbsp;]</div>".
  
  login() ->
      header("echessd - Login", []) ++
          h1("echessd login") ++
          "<div class=navig>[&nbsp;<a href='?goto=register'>Register new user</a>&nbsp;]</div>"
          "<form method=post>"
          "<input name=action type=hidden value=login>"
          "Login:    <input name=username type=text><br>"
  
negative.code:     header("echessd - Under construction", []) ++
          h1("Not implemented yet") ++
          "" ++
          navig_links([{"javascript: history.back();", "Back"}]) ++
          footer([]).
  
  