<%~GForum::Post::View::get($in.root_id)%>
<%~unless post_id%><%set error = GForum::language('POST_DOES_NOT_EXIST')%><%include error.html%><%endparse%><%endunless~%>
<%~set search_widget = 1%>
<!DOCTYPE html >
<html lang="en">
<head>
  <title><%cat_full_name%>: <%forum_name%>: <%if post_deleted%>Post deleted by <%post_deleted_by%>: <%endif%><%post_subject%>: Move Thread</title>
<%include include_common_head.html%>
</head>

<body class="page-<%page_id%>">
  <div class="container-b">
    <%include include_header.html%>

    <div class="main">
      <div class="contentwrapper clearfix">
        <div class="sidebar">
            <%include include_sidebar.html%>
        </div>
        <%~set content_header_title = 'Thread Move'%>
        <%~set btn_new = 1%>
        <%~init array breadcrumbs%><%init hash breadcrumbs.0%><%init hash breadcrumbs.1%>
        <%~set breadcrumbs.0.name = $forum_name%>
        <%~set breadcrumbs.0.url  = GForum::SEO::url(params => "forum=$forum_id")%>
        <%~set breadcrumbs.1.name = $content_header_title%>

        <%include include_breadcrumb.html%>

        <div class="content"><%-- start content--%>
          <%include include_content_header.html%>
          <p>
            You have chosen to move the thread '<a href="<%GForum::SEO::url(type => "post", id => $post_id, anchor => "p$post_id")%>"><%post_subject%></a>',
            <%if post_replies%>containing <%post_replies%> repl<%if post_replies == 1%>y<%else%>ies<%endif%>,<%endif%>
            started by
            <%set include_username_display = $post_username~%>
            <%include include_username.html%>
            on <%post_date%>.
          </p>
          <p>
            Please select a forum to move the post to:
          </p>

          <div class="simple-form">
            <form action="<%GForum::SEO::url()%>" method="post">
              <%hidden_form%>
              <input type="hidden" name="root_id" value="<%in.root_id%>" />
              <input type="hidden" name="do" value="post_move" />
              <%GForum::Forum::moderator_tpl_options(without => $forum_id)%>
              <select name="forum_id">
                <option value="">---</option>
                <%~set last_cat_id = -1%>
                <%~loop moderator_tpl_loop%>
                  <%~if cat_id != $last_cat_id%>
                    <%~unless last_cat_id == -1%>
                </optgroup>
                    <%~endunless%>
                    <%~set last_cat_id = $cat_id%>
                <optgroup label="<%cat_full_name%>">
                  <%~endif%>
                <option value="<%forum_id%>"><%forum_name%></option>
                <%~endloop%>
                </optgroup>
              </select>
              <input type="submit" value="Move Thread" class="btn" />

              <%if forum_move_pointer%><br />
              <input type="checkbox" name="skip_pointer" id="skip_pointer" value="1" class="checkbox" /> <label for="skip_pointer">Don't leave moved post pointer</label>
              <%endif%>
            </form>
          </div>

        </div><%-- end content --%>
      </div><%-- end contentwrapper --%>
    </div><%-- end main --%>
    <%include include_footer.html%>
  </div>
</body>
<%~include include_global_js.html%>
</html>
