Location: PHPKode > projects > Uchome and Discuz > template/default/cp_thread.htm
<!--{template header}-->

<!--{if $_GET['op'] == 'edit'}-->



<h1>Edit</h1>
<a href="javascript:hideMenu();" class="float_del" title="Close">Close</a>
<div class="popupmenu_inner">

	<form id="editpostform_{$pid}" name="editpostform_{$pid}" method="post" action="cp.php?ac=thread&op=edit&pid=$pid&tagid=$tagid&eventid=$eventid">
		<table>
			<tr>
				<th style="vertical-align: top;"><label for="message">Content:</label></th>
				<td>
					<a href="###" id="face_{$pid}" onclick="showFace(this.id, 'message_{$pid}');return false;"><img src="image/facelist.gif" align="absmiddle" /></a>
					<img src="image/zoomin.gif" onmouseover="this.style.cursor='pointer'" onclick="zoomTextarea('message_{$pid}', 1)">
					<img src="image/zoomout.gif" onmouseover="this.style.cursor='pointer'" onclick="zoomTextarea('message_{$pid}', 0)"><br/>
					<textarea id="message_{$pid}" name="message" onkeydown="ctrlEnter(event, 'posteditsubmit_btn');" <!--{if $post['isthread']}-->rows="18" style="width:98%;"<!--{else}-->rows="8" cols="50"<!--{/if}-->>$post[message]</textarea>
				</td>
			</tr>
			<tbody id="editwebimg">
				<tr>
					<th>Photo:</th>
					<td>
						<input class="t_input" type="text" onfocus="if(this.value == 'http://')this.value='';" onblur="if(this.value=='')this.value='http://'" name="pics[]" value="http://" size="40" />&nbsp;
						<a href="javascript:;" onclick="insertWebImg(this.previousSibling.previousSibling)">Insert</a> &nbsp;
						<a href="javascript:;" onclick="delRow(this, 'editwebimg')">Remove</a>
					</td>
				</tr>
			</tbody>
			<tr>
				<th>&nbsp;</th>
				<td>
					<a href="javascript:;" onclick="copyRow('editwebimg')">+more picture</a> <span class="gray">only support URL which end with .jpg¡¢.gif¡¢.png</span>
				</td>
			</tr>
			<tr>
				<th>&nbsp;</th>
				<td>
				<input type="hidden" name="pid" value="$pid">
				<input type="hidden" name="refer" value="$_SGLOBAL[refer]" />
				<input type="hidden" name="posteditsubmit" value="true" />
				<!--{if $_SGLOBAL[inajax]}-->
				<input type="button" name="posteditsubmit_btn" id="posteditsubmit_btn" value="Submit" class="submit" onclick="ajaxpost('editpostform_{$pid}', 'post_edit', 1)" />
				<!--{else}-->
				<input type="submit" name="posteditsubmit_btn" id="posteditsubmit_btn" value="Submit" class="submit" />
				<!--{/if}-->
				
				<div id="__editpostform_{$pid}"></div>
				</td>
			</tr>
		</table>
		<input type="hidden" name="formhash" value="<!--{eval echo formhash();}-->" />
	</form>
</div>

<!--{elseif $_GET['op'] == 'delete'}-->

<h1>Delete Replies</h1>
<a href="javascript:hideMenu();" class="float_del" title="Close">Close</a>
<div class="popupmenu_inner" id="__deletepostform_{$pid}">
<form id="deletepostform_{$pid}" name="deletepostform_{$pid}" method="post" action="cp.php?ac=thread&op=delete&pid=$pid&tagid=$tagid&eventid=$eventid">
	<p>Are you sure do you want to delete this?</p>
	<p class="btn_line">
		<input type="hidden" name="refer" value="$_SGLOBAL[refer]" />
		<!--{if $_SGLOBAL[inajax]}-->
		<input type="hidden" name="postdeletesubmit" value="true" />
		<input type="button" name="postdeletesubmit_btn" value="Submit" class="submit" onclick="ajaxpost('deletepostform_{$pid}', 'post_delete', 2000)" />&nbsp;
		<!--{else}-->
		<input type="submit" name="postdeletesubmit" value="Submit" class="submit" />&nbsp;
		<!--{/if}-->
	</p>
	<input type="hidden" name="formhash" value="<!--{eval echo formhash();}-->" />
</form>
</div>

<!--{elseif $_GET['op'] == 'edithot'}-->

<h1>Ajust the heat point</h1>
<a href="javascript:hideMenu();" class="float_del" title="Close">Close</a>
<div class="popupmenu_inner">
<form method="post" action="cp.php?ac=thread&op=edithot&tid=$tid">
	<p class="btn_line">
		New Heat Value:<input type="text" name="hot" value="$thread[hot]" size="5">
		<input type="hidden" name="refer" value="$_SGLOBAL[refer]" />
		<input type="hidden" name="hotsubmit" value="true" />
		<input type="submit" name="btnsubmit" value="Submit" class="submit" />
	</p>
<input type="hidden" name="formhash" value="<!--{eval echo formhash();}-->" />
</form>
</div>

<!--{elseif $_GET['op'] == 'reply'}-->

<h1>Reply</h1>
<a href="javascript:hideMenu();" class="float_del" title="Close">Close</a>
<div class="popupmenu_inner">
<form id="reply_postform_{$post[pid]}" name="reply_postform_{$post[pid]}" method="post" action="cp.php?ac=thread&eventid=$eventid">
	<table>
		<tr>
			<th><label for="message">Content:</label></th>
			<td>
				<a href="###" id="face_{$post[pid]}" onclick="showFace(this.id, 'message_{$post[pid]}');return false;"><img src="image/facelist.gif" align="absmiddle" /></a>
				<img src="image/zoomin.gif" onmouseover="this.style.cursor='pointer'" onclick="zoomTextarea('message_{$post[pid]}', 1)">
				<img src="image/zoomout.gif" onmouseover="this.style.cursor='pointer'" onclick="zoomTextarea('message_{$post[pid]}', 0)"><br/>
				<textarea id="message_{$post[pid]}" name="message" onkeydown="ctrlEnter(event, 'postsubmit');" rows="8" cols="70"></textarea>
			</td>
		</tr>
		<tbody id="replybimg">
			<tr>
				<td>Photo:</td>
				<td>
					<input class="t_input" type="text" name="pics[]" onfocus="if(this.value == 'http://')this.value='';" onblur="if(this.value=='')this.value='http://'" value="http://" size="30" />&nbsp;
					<a href="javascript:;" onclick="insertWebImg(this.previousSibling.previousSibling)">Insert</a> &nbsp;
					<a href="javascript:;" onclick="delRow(this, 'replybimg')">Remove</a>
				</td>
			</tr>
		</tbody>
		<tr>
			<th>&nbsp;</th>
			<td>
				<a href="javascript:;" onclick="copyRow('replybimg')">+more photo</a> <span class="gray">Only support URL which end with .jpg, .gif, .png</span>
			</td>
		</tr>

		<tr>
			<td>&nbsp;</td>
			<td>
				<input type="hidden" name="refer" value="$_SGLOBAL[refer]" />
				<input type="hidden" name="tid" value="$post[tid]" />
				<input type="hidden" name="pid" value="$post[pid]" />
				<!--{if $_SGLOBAL[inajax]}-->
				<input type="hidden" name="postsubmit" value="true" />
				<input type="submit" name="postsubmit_btn" id="postsubmit" value="Reply" class="submit" onclick="ajaxpost('reply_postform_{$post[pid]}', 'post_add', 1)" />
				<!--{else}-->
				<input type="submit" name="postsubmit" id="postsubmit" value="Reply" class="submit" />
				<!--{/if}-->
				<div id="__reply_postform_{$post[pid]}"></div>
			</td>
		</tr>
	</table>
	<input type="hidden" name="formhash" value="<!--{eval echo formhash();}-->" />
</form>
</div>

<!--{else}-->

<script language="javascript" src="image/editor/editor_function.js"></script>
<script language="javascript" src="source/script_blog.js"></script>

<!--{if $topic}-->
	<!--{template cp_topic_menu}-->
<!--{else}-->
	<h2 class="title">
		<!--{if $eventid}-->
		<img src="image/app/event.gif">Event - <a href="space.php?do=event&id=$eventid">$event[title]</a>
		<!--{else}-->
		<img src="image/app/mtag.gif" />Groups
		<!--{/if}-->
	</h2>
	<div class="tabs_header">
		<ul class="tabs">
		<!--{if $eventid}-->
			<li class="active"><a href="cp.php?ac=thread&eventid=$eventid"><span>Create Event Topic</span></a></li>
			<li><a href="space.php?do=event&id=$eventid"><span>Back to Event</span></a></li>
		<!--{elseif $thread}-->
			<li class="active"><a href="cp.php?ac=thread&op=edit&pid=$post[pid]"><span>Edit Topic</span></a></li>
			<li><a href="space.php?do=mtag&tagid=$thread[tagid]&view=list"><span>Back to Forum</span></a></li>
		<!--{else}-->
			<li class="active"><a href="cp.php?ac=thread"><span>Create Discussion</span></a></li>
			<li><a href="space.php?do=thread&view=me"><span>My Discussion</span></a></li>
		<!--{/if}-->
		</ul>
	</div>
<!--{/if}-->

<div class="c_form">

<style>
	.userData {behavior:url(#default#userdata);}
</style>

	<form method="post" action="cp.php?ac=thread&eventid=$eventid" enctype="multipart/form-data">
		<table cellspacing="4" cellpadding="4" width="100%" class="infotable">
		<!--{if $eventid}-->
			<tr>
				<td>
					<input type="hidden" name="tagid" maxlength="100" value="$tagid" />
				</td>
			</tr>
		<!--{elseif !$tagid}-->
			<tr>
				<td>
				<select name="tagid" id="tagid">
				<!--{loop $mtaglist $fieldid $values}-->
				<!--{loop $values $value}-->
					<option value="$value[tagid]">[{$_SGLOBAL[profield][$value[fieldid]][title]}] $value[tagname]</option>>
				<!--{/loop}-->
				<!--{/loop}-->
				</select>
				<a href="cp.php?ac=mtag">Create new Group</a>
				</td>
			</tr>
		<!--{else}-->
			<tr>
				<td>$mtag[tagname]<!--{if !$thread}--> [<a href="cp.php?ac=thread">Switch</a>]<!--{/if}-->
					<input type="hidden" name="tagid" value="$tagid" />
				</td>
			</tr>
		<!--{/if}-->
			<tr>
				<td><input type="text" class="t_input" id="subject" name="subject" value="$thread[subject]" size="60" /></td>
			</tr>
			<tr>
				<td>
				<a id="doodleBox" href="magic.php?mid=doodle&showid=blog_doodle&target=uchome-ttHtmlEditor&from=editor" style="display:none"></a>
				<textarea class="userData" name="message" id="uchome-ttHtmlEditor" style="height:100%;width:100%;display:none;border:0px">$post[message]</textarea>
				<iframe src="editor.php?charset=$_SC[charset]&allowhtml=<!--{eval echo checkperm('allowhtml')}-->&doodle=<!--{if isset($_SGLOBAL[magic][doodle])}-->1<!--{/if}-->" name="uchome-ifrHtmlEditor" id="uchome-ifrHtmlEditor" scrolling="no" border="0" frameborder="0" style="width:100%;border: 1px solid #C5C5C5;" height="400"></iframe>
				</td>
			</tr>

			<!--{if checkperm('seccode')}-->
			<!--{if $_SCONFIG['questionmode']}-->
			<tr>
				<td>
					<p>Answer Verification Question</p>
					<p><!--{eval question();}--></p>
					<input type="text" id="seccode" name="seccode" value="" size="15" class="t_input" />
				</td>
			</tr>
			<!--{else}-->
			<tr>
				<td>
					<p>Verification Code</p>
					<script>seccode();</script>
					<p>Enter the above 4 letter/number, can't read <a href="javascript:updateseccode()"> Get new</a></p>
					<input type="text" id="seccode" name="seccode" value="" size="15" class="t_input" />
				</td>
			</tr>
			<!--{/if}-->
			<!--{/if}-->

			<tr>
				<td>
					<input type="checkbox" name="makefeed" id="makefeed" value="1"<!--{if empty($mtag['viewperm']) && ckprivacy('thread', 1)}--> checked<!--{/if}-->> Have RSS Feed (<a href="cp.php?ac=privacy#feed" target="_blank">Change the default setting</a>)
				</td>
			</tr>

		</table>
		<input type="hidden" name="tid" value="$thread[tid]" />
		<input type="hidden" name="threadsubmit" value="true" />
		<input type="button" id="threadbutton" name="threadbutton" value="Submit" onclick="validate(this);" style="display: none;" />
		<input type="hidden" name="topicid" value="$_GET[topicid]" />
		<input type="hidden" name="formhash" value="<!--{eval echo formhash();}-->" />
	</form>
	<!--{if !$thread['uid'] || $thread['uid']==$_SGLOBAL['supe_uid']}-->
	<table cellspacing="4" cellpadding="4" width="100%" class="infotable">
		<tr><td>
		<input type="button" name="clickbutton[]" value="Upload image" class="button" onclick="edit_album_show('pic')">
		<input type="button" name="clickbutton[]" value="Insert Picture" class="button" onclick="edit_album_show('album')">
		</td></tr>
	</table>
	<!--{/if}-->
	<table cellspacing="4" cellpadding="4" width="100%" id="uchome-edit-pic" class="infotable" style="display:none;">
		<tr>
			<td>
				<strong>Select Picture</strong>:
				<table summary="Upload" cellspacing="2" cellpadding="0">
					<tbody id="attachbodyhidden" style="display:none">
						<tr>
							<td>
								<form method="post" id="upload" action="cp.php?ac=upload" enctype="multipart/form-data" target="uploadframe" style="background: transparent;">
									<input type="file" name="attach" style="border: 1px solid #CCC;" />
									<span id="localfile"></span>
									<input type="hidden" name="uploadsubmit" id="uploadsubmit" value="true" />
									<input type="hidden" name="albumid" id="albumid" value="0" />
									<input type="hidden" name="formhash" value="<!--{eval echo formhash();}-->" />
								</form>
							</td>
						</tr>
					</tbody>
					<tbody id="attachbody"></tbody>
				</table>
				<strong>Save Album</strong>:
				<table cellspacing="2" cellpadding="0">
					<tr>
						<td>
							<select name="albumid" id="uploadalbum" onchange="addSort(this)">
								<option value="-1">Select Album</option>
								<option value="-1">Defualt Album</option>
								<!--{loop $albums $value}-->
								<option value="$value[albumid]">$value[albumname]</option>
								<!--{/loop}-->
								<option value="addoption" style="color:red;">+New Album</option>
							</select>
							<script src="source/script_upload.js" type="text/javascript"></script>
							<iframe id="uploadframe" name="uploadframe" width="0" height="0" marginwidth="0" frameborder="0" src="about:blank"></iframe>
						</td>
					</tr>
				</table>
			</td>
		</tr>
	</table>
	<table cellspacing="4" cellpadding="4" width="100%" class="infotable" id="uchome-edit-album" style="display:none;">
		<tr>
			<td>
				Select Album:<select name="view_albumid" onchange="picView(this.value)">
					<option value="none">Select Album</option>
					<option value="0">Default Album</option>
					<!--{loop $albums $value}-->
					<option value="$value[albumid]">$value[albumname]</option>
					<!--{/loop}-->
				</select> (click the picture to insert)
				<div id="albumpic_body"></div>
			</td>
		</tr>
	</table>
	<table cellspacing="4" cellpadding="4" width="100%" class="infotable">
		<tr>
			<td><input type="button" id="issuance" onclick="document.getElementById('threadbutton').click();" value="Submit" class="submit" /></td>
		</tr>
	</table>
</div>

<!--{/if}-->

<!--{template footer}-->
Return current item: Uchome and Discuz