PDA

توجه ! این یک نسخه آرشیو شده می باشد و در این حالت شما عکسی را مشاهده نمی کنید برای مشاهده کامل متن و عکسها بر روی لینک مقابل کلیک کنید : پاسخ سریع مجهز



Borna66
12-25-2009, 02:17 PM
نمیدونستم باید چه عنوانی برای تاپیک انتخاب کنم! http://pnu-club.com/imported/mising.jpg در هر صورت منظور اضافه کردن "عنوان موضوع"، "نماد ارسال"، "شکلک ها" و ... به بخش پاسخ سریع هست. مانند این تصویر:

http://pnu-club.com/imported/mising.jpg (http://www.mybbhelp.ir/attachment.php?aid=202)

کار راحتیه. فقط کافیه مراحل زیر رو طی کنید تا تغییراتی که ایجاد میشه هم از نظر امنیتی مشکلی رو برای فروم ایجاد نکنند و هم اینکه کمترین میزان پردازش انجام بشه.

* توضیحاتی که در زیر میخونید برای نسخه ۱.۴ است.

فایل showthread.php رو باز کنید و این خط رو پیدا کنید:

کد PHP:



eval("\$quickreply = \"".$templates->get("showthread_quickreply")."\";");


حالا به بالای این خط، کد زیر رو اضافه کنید (یعنی حتماً قبل از اون خطی که پیدا کردید):

کد PHP:




$lang->load("newreply");
if($forum['allowpicons'] != 0)
{
$posticons = get_post_icons();
}
if($mybb->settings['bbcodeinserter'] != 0 && $forum['allowmycode'] != 0 && (!$mybb->user['uid'] || $mybb->user['showcodebuttons'] != 0))
{
$codebuttons = build_mycode_inserter();
if($forum['allowsmilies'] != 0)
{
$smilieinserter = build_clickable_smilies();
}
}
$codebuttons = build_mycode_inserter();




فایل رو آپلود کنید.
در پنل مدیریت مای بی بی به بخش ویرایش تمپلت ها برید و تمپلت showthread_quickreply رو باز کنید. محتوای این تمپلت در قالب های مختلف، متفاوته. این خط رو داخل تمپلت پیدا کنید:

کد PHP:


<tbody style="{$collapsed['quickreply_e']}" id="quickreply_e">




و دقیقاً بعد از اون کد زیر رو اضافه کنید:

کد PHP:


<tr>
<td class="trow2" width="20%"><strong>{$lang->post_subject}</strong></td>
<td class="trow2"><input type="text" class="textbox" name="subject" size="40" maxlength="85" value="RE: {$thread['subject']}" tabindex="1" /></td>
</tr>
{$posticons}
<tr>




این خط رو هم که احتمالاً در خطوط ابتدایی همین تمپلت showthread_quickreply هست رو پاک کنید:

کد PHP:


<input type="hidden" name="subject" value="RE: {$thread['subject']}" />



هر کجا هم خواستید شکلک ها نمایش داده بشند کد زیر رو قرار بدید:

کد PHP:


{$smilieinserter}



بعد از خطی که اولش نوشته کد PHP:


<textarea


هم باید این کد قرار بگیره که در حقیقت برای اضافه کردن دکمه ها به ادیتوره:

کد PHP:


{$codebuttons}





نمونه ای از تمپلت showthread_quickreply تغییر یافته (مستقیماً copy/paste نکنید! اول در یک فایل متنی (txt) بریزید و بعد، از اونجا کپی کنید):

کد PHP:


<br />
<form method="post" action="newreply.php?tid={$tid}&amp;processed=1" name="quick_reply_form" id="quick_reply_form">
<input type="hidden" name="my_post_key" value="{$mybb->post_code}" />
<input type="hidden" name="action" value="do_newreply" />
<input type="hidden" name="posthash" value="{$posthash}" id="posthash" />
<input type="hidden" name="quoted_ids" value="" id="quoted_ids" />
<input type="hidden" name="lastpid" id="lastpid" value="{$last_pid}" />
<input type="hidden" name="from_page" value="{$page}" />
<input type="hidden" name="tid" value="{$tid}" />
<input type="hidden" name="method" value="quickreply" />

<table border="0" cellspacing="{$theme['borderwidth']}" cellpadding="{$theme['tablespace']}" class="tborder">
<thead>
<tr>
<td class="thead" colspan="2">
<div class="expcolimage"><img src="{$theme['imgdir']}/collapse{$collapsedimg['quickreply']}.gif" id="quickreply_img" class="expander" alt="[-]" title="[-]" /></div>
<div><strong>{$lang->quick_reply}</strong></div>
</td>
</tr>
</thead>
<tbody style="{$collapsed['quickreply_e']}" id="quickreply_e">
<tr>
<td class="trow2" width="20%"><strong>{$lang->post_subject}</strong></td>
<td class="trow2"><input type="text" class="textbox" name="subject" size="40" maxlength="85" value="RE: {$thread['subject']}" tabindex="1" /></td>
</tr>
{$posticons}
<tr>
<td class="trow2" valign="top" width="22%">
{$smilieinserter}<br />
<span class="smalltext">
<label><input type="checkbox" class="checkbox" name="postoptions[signature]" value="1" {$postoptionschecked['signature']} />&nbsp;<strong>{$lang->signature}</strong></label><br />
<label><input type="checkbox" class="checkbox" name="postoptions[disablesmilies]" value="1" />&nbsp;<strong>{$lang->disable_smilies}</strong></label>{$closeoption}</span>
</td>
<td class="trow2">
<div>
<textarea rows="13" cols="90" style="width: 590px; margin:0;" name="message" id="message" tabindex="1"></textarea>


{$codebuttons}
</div>
<script type="text/javascript">document.write('<div class="editor_control_bar" style="width: 90%; padding: 4px; margin-top: 3px; display: none;" id="quickreply_multiquote"><span class="smalltext">{$lang->quickreply_multiquote_selected} <a href="javascript:Thread.loadMultiQuoted();">{$lang->quickreply_multiquote_now}<\/a> {$lang->or} <a href="javascript:Thread.clearMultiQuoted();">{$lang->quickreply_multiquote_deselect}<\/a>.<\/span><\/div>');</script>
</td>
</tr>
{$captcha}
<tr>
<td colspan="2" align="center" class="tfoot"><input type="submit" class="button" value="{$lang->post_reply}" tabindex="2" accesskey="s" id="quick_reply_submit" /> <input type="submit" class="button" name="previewpost" value="{$lang->preview_post}" tabindex="3" /></td>
</tr>
</tbody>
</table>
</form>