root/trunk/Vanilla/templates/vanilla+comments/comment_preview.mtml @ 919

Revision 919, 6.4 kB (checked in by bsmith, 16 months ago)

various updates

Line 
1<mt:IncludeBlock module="wrapper">
2   
3    <mt:setvarblock name="html_head" append="1">
4        <style type="text/css" media="screen">
5            form {
6                width: 50%;
7            }
8        </style>
9    </mt:setvarblock>
10
11    <mt:SetVarBlock name="html_head">
12    <script type="text/javascript">
13    /* <![CDATA[ */
14    var user = <$mt:UserSessionState$>;
15    var is_preview = true;
16    /* ]]> */
17    </script>
18    </mt:SetVarBlock>
19
20    <h1><__trans phrase="Previewing your Comment"></h1>
21
22    <div id="comments">
23       
24        <ol class="comments-content">
25            <li>
26                <div class="comment-header">
27                    <$mt:CommentAuthorIdentity$>
28                    <mt:IfCommentParent>
29                        <__trans phrase="[_1] replied to [_2]<a href="[_3]">comment from [_4]</a>[_5]" params="<$mt:CommentAuthorLink$>%%<mt:CommentParent>%%<$mt:CommentLink$>%%<$mt:CommentAuthor$>%%</mt:CommentParent>">
30                    <mt:Else>
31                        <$mt:CommentAuthorLink$>
32                    </mt:IfCommentParent>
33                    | <a href="<$mt:CommentLink$>"><abbr class="published" title="<$mt:CommentDate format_name="iso8601"$>"><$mt:CommentDate$></abbr></a>
34                </div>
35                <div class="comment-body">
36                    <$mt:CommentBody$>
37                </div>
38            </li>
39        </ol>
40
41        <mt:IfCommentsAccepted>
42        <div id="comments-open">
43            <h2 class="comments-open-header"><__trans phrase="Leave a comment"></h2>
44            <div class="comments-open-content">
45                <div id="comment-greeting"></div>
46                <form method="post" action="<$mt:CGIPath$><$mt:CommentScript$>" name="comments_form" id="comments-form" onsubmit="return mtCommentOnSubmit(this)">
47                    <input type="hidden" name="static" value="1" />
48                    <input type="hidden" name="entry_id" value="<$mt:EntryID$>" />
49                    <input type="hidden" name="__lang" value="<$mt:BlogLanguage$>" />
50                    <input type="hidden" name="parent_id" value="<$mt:CommentParentID$>" id="comment-parent-id" />
51                    <input type="hidden" name="armor" value="1" />
52                    <input type="hidden" name="preview" value="" />
53                    <input type="hidden" name="sid" value="" />
54                    <div id="comments-open-data">
55                        <div>
56                            <label for="comment-author"><__trans phrase="Name"></label>
57                            <input id="comment-author" name="author" size="30" value="" onfocus="mtCommentFormOnFocus()" />
58                        </div>
59                        <div>
60                            <label for="comment-email"><__trans phrase="Email Address"></label>
61                            <input id="comment-email" name="email" size="30" value="" onfocus="mtCommentFormOnFocus()" />
62                        </div>
63                        <div>
64                            <label for="comment-url"><__trans phrase="URL"></label>
65                            <input id="comment-url" name="url" size="30" value="" onfocus="mtCommentFormOnFocus()" />
66                        </div>
67                    </div>
68                    <div id="comment-form-reply"<mt:IfCommentParent><mt:Else> style="display:none"</mt:IfCommentParent>>
69                        <input type="checkbox" id="comment-reply" name="comment_reply" value="<$mt:CommentParentID$>"<mt:IfCommentParent> checked="checked"</mt:IfCommentParent> onclick="mtSetCommentParentID()" />
70                        <label for="comment-reply" id="comment-reply-label"><mt:IfCommentParent><__trans phrase="Replying to comment from [_1]" params="<mt:CommentParent><$mt:CommentAuthor$></mt:CommentParent>"></mt:IfCommentParent></label>
71                    </div>
72                    <div id="comments-open-text">
73                        <label for="comment-text"><__trans phrase="Comments">
74                        <mt:IfAllowCommentHTML><__trans phrase="(You may use HTML tags for style)"></mt:IfAllowCommentHTML></label>
75                        <textarea id="comment-text" name="text" rows="15" cols="50" onfocus="mtCommentFormOnFocus()"><$mt:CommentBody autolink="0" sanitize="0" convert_breaks="0" encode_html="1"$></textarea>
76                    </div>
77                    <div id="comments-open-captcha"></div>
78                    <div id="comments-open-footer">
79                        <input type="submit" accesskey="v" name="preview_button" id="comment-preview" value="<__trans phrase="Preview">" onclick="this.form.preview.value='1';" />
80                        <input type="submit" accesskey="s" name="post" id="comment-submit" value="<__trans phrase="Submit">" />
81                        <input type="button" name="cancel" id="comment-cancel" value="<__trans phrase="Cancel">" onclick="window.location='<$mt:EntryPermalink$>'" />
82                    </div>
83                </form>
84            </div>
85        </div>
86        <script type="text/javascript">
87        <!--
88        mtAttachEvent("load", mtEntryOnLoad);
89        mtAttachEvent("unload", mtEntryOnUnload);
90        //-->
91        </script>
92        </mt:IfCommentsAccepted>
93
94        <mt:Comments>
95            <mt:CommentsHeader>
96        <h2 class="comments-header"><__trans phrase="Comments"></h2>
97        <ol class="comments-content">
98            </mt:CommentsHeader>
99            <li id="comment-<$mt:CommentID$>">
100                <div class="comment-header">
101                    <$mt:CommentAuthorIdentity$>
102                    <mt:IfCommentParent>
103                        <__trans phrase="[_1] replied to [_2]<a href="[_3]">comment from [_4]</a>[_5]" params="<$mt:CommentAuthorLink$>%%<mt:CommentParent>%%<$mt:CommentLink$>%%<$mt:CommentAuthor$>%%</mt:CommentParent>">
104                    <mt:Else>
105                        <$mt:CommentAuthorLink$>
106                    </mt:IfCommentParent>
107                    | <a href="<$mt:CommentLink$>"><abbr class="published" title="<$mt:CommentDate format_name="iso8601"$>"><$mt:CommentDate$></abbr></a>
108                    <mt:IfCommentsAccepted>
109                    | <$mt:CommentReplyToLink$>
110                    </mt:IfCommentsAccepted>
111                </div>
112                <div class="comment-body">
113                    <$mt:CommentBody$>
114                </div>
115            </li>
116            <mt:CommentsFooter>
117        </ol>
118            </mt:CommentsFooter>
119        </mt:Comments>
120
121    </div>
122
123</mt:IncludeBlock>
Note: See TracBrowser for help on using the browser.