those requesting quick reply!!

This forum is now closed as part of retiring phpBB2
Forum rules
READ: phpBB.com Board-Wide Rules and Regulations

This forum is now closed due to phpBB2.0 being retired.
danb00
Registered User
Posts: 1025
Joined: Sun Dec 15, 2002 9:41 pm
Location: Inside Mod:Extreme PHPBB
Contact:

those requesting quick reply!!

Post by danb00 » Thu Oct 09, 2003 12:07 pm

thanks to Smartor
for this!!

(get it added to the mod db!!)
##############################################################
## MOD Title: Quick Reply
## MOD Author: Smartor < smartor_xp@hotmail.com > (Hoang Ngoc Tu) http://smartor.is-root.com
## MOD Description: This will add a quick-reply form below every topics
## It will only display when user has the Reply access
## MOD Version: 1.0.5
##
## Installation Level: easy
## Installation Time: 5 Minutes
## Files To Edit: 3
## viewtopic.php,
## language/lang_english/lang_main.php
## templates/subSilver/viewtopic_body.tpl
## Included Files: N/A
##############################################################
## This MOD is released under the GPL License.
## Intellectual Property is retained by the MOD Author(s) listed above
##############################################################
## Author Notes:
##
##############################################################
## Before Adding This MOD To Your Forum, You Should Back Up All Files Related To This MOD
##############################################################

#
#-----[ OPEN ]------------------------------------------
#
viewtopic.php

#
#-----[ FIND ]------------------------------------------
#
$template->pparse('body');

include($phpbb_root_path . 'includes/page_tail.'.$phpEx);

#
#-----[ BEFORE, ADD ]------------------------------------
#
//
// Quick Reply Mod
//
if ( ((!$is_auth['auth_reply']) or ($forum_topic_data['forum_status'] == FORUM_LOCKED) or ($forum_topic_data['topic_status'] == TOPIC_LOCKED)) and ($userdata['user_level'] != ADMIN) )
{
$quick_reply_form = "";
}
else
{
$notify_user = (( $userdata['session_logged_in'] ) ? $userdata['user_notify'] : 0) ? '1' : '';
$attach_sig = (( $userdata['session_logged_in'] ) ? $userdata['user_attachsig'] : 0) ? '1' : '';
$quick_reply_form = "
<script language='JavaScript' type='text/javascript'>
function checkForm() {
formErrors = false;
if (document.post.message.value.length < 2) {
formErrors = '" . $lang['Empty_message'] . "';
}
if (formErrors) {
alert(formErrors);
return false;
} else {
return true;
}
}
</script>
<form action='".append_sid("posting.$phpEx")."' method='post' name='post' onsubmit='return checkForm(this)'>
<span class='genmed'><b>".$lang["Quick_Reply"].":</b><br /><br />
";

if (!$userdata['session_logged_in'])
{
$quick_reply_form .= $lang['Username'] . ":&<input class='post' type='text' name='username' size='25' maxlength='25' value='' /><br />";
}

$quick_reply_form .= "
<textarea class='post' name='message' rows='10' cols='50' wrap='virtual'></textarea><br />
<input type='hidden' name='attach_sig' value='" . $attach_sig . "' />
<input type='hidden' name='mode' value='reply' />
<input type='hidden' name='sid' value='" . $userdata['session_id'] . "' />
<input type='hidden' name='t' value='" . $topic_id . "' />
<input type='hidden' name='notify' value='" . $notify . "' /><br />
<input type='submit' name='preview' class='liteoption' value='".$lang['Preview']."' />&
<input type='submit' name='post' class='mainoption' value='".$lang["Submit"]."' />
</form></span>
";
}

$template->assign_vars(array(
'QUICK_REPLY_FORM' => $quick_reply_form)
);
//
// END Quick Reply Mod
//

#
#-----[ OPEN ]------------------------------------------
#
lang_main.php

#
#-----[ FIND ]------------------------------------------
#
//
// That's all Folks!

#
#-----[ BEFORE, ADD ]------------------------------------
#
// Quick Reply MOD
$lang['Quick_Reply'] = 'Quick Reply';

#
#-----[ OPEN ]------------------------------------------
#
viewtopic_body.tpl

#
#-----[ FIND ]------------------------------------------
#
{S_TOPIC_ADMIN}

#
#-----[ AFTER, ADD ]------------------------------------
#
{QUICK_REPLY_FORM}

#
#-----[ SAVE/CLOSE ALL FILES ]------------------------------------------
#
# EoM

Foohon Pie
Registered User
Posts: 107
Joined: Fri Oct 10, 2003 7:52 am
Contact:

Post by Foohon Pie » Fri Oct 10, 2003 4:54 pm

Great Stuff.

small note though:

in viewtopic.php:

<input type='submit' name='preview' class='liteoption' value='".$lang['Preview']."' />&
<input type='submit' name='post' class='mainoption' value='".$lang["Submit"]."' />


should be:

<input type='submit' name='preview' class='liteoption' value='".$lang['Preview']."' /> &
<input type='submit' name='post' class='mainoption' value='".$lang["Submit"]."' />


VERY subtle difference, but I'm a nut for symmetry
signature huh? *grabs pen*
x__I_like_pie__
www.vincepoops.com

jet192
Registered User
Posts: 52
Joined: Sun Aug 03, 2003 7:25 pm

Post by jet192 » Fri Oct 10, 2003 5:14 pm

thats the quick reply mod I use.. i have it installed on 4 different styles and it works perfect.

Foohon Pie
Registered User
Posts: 107
Joined: Fri Oct 10, 2003 7:52 am
Contact:

Post by Foohon Pie » Fri Oct 10, 2003 5:16 pm

yep, works like a charm
signature huh? *grabs pen*
x__I_like_pie__
www.vincepoops.com

Kendjin
Registered User
Posts: 375
Joined: Mon Sep 22, 2003 2:12 pm
Location: UK
Contact:

Post by Kendjin » Fri Oct 10, 2003 5:18 pm

Compatible with which PhpBB ? 2.0.4 / 2.0.5 / 2.0.6 ?
My Avatar should say: I WANT YOU!!! to leave me alone.
But he's wearing a crimbo hat ^_^
A_Jelly_Doughnut is my idol ^-^

Foohon Pie
Registered User
Posts: 107
Joined: Fri Oct 10, 2003 7:52 am
Contact:

Post by Foohon Pie » Fri Oct 10, 2003 5:20 pm

I'm using 2.0.6, and it's workin good enough for me.

See for yourself.
signature huh? *grabs pen*
x__I_like_pie__
www.vincepoops.com

Kendjin
Registered User
Posts: 375
Joined: Mon Sep 22, 2003 2:12 pm
Location: UK
Contact:

Post by Kendjin » Fri Oct 10, 2003 5:21 pm

hmmm the layout of the quick reply box is a bit dodgy for my taste, I'll wait till someone makes one that's alot like a post size.,..
My Avatar should say: I WANT YOU!!! to leave me alone.
But he's wearing a crimbo hat ^_^
A_Jelly_Doughnut is my idol ^-^

Foohon Pie
Registered User
Posts: 107
Joined: Fri Oct 10, 2003 7:52 am
Contact:

Post by Foohon Pie » Fri Oct 10, 2003 5:37 pm

Yeah, It's a bit too short in width for me as well, but a simple size adjustment should fix the problem. Also, I would rather have it show in between the posts and the new topic and post reply buttons.

If I modify it any, i'll post back here.

If somebody out there would beat me to it, it would be great. Also, does anybody know how to add a "quote selected text" button? That would be incredibly useful for a quick reply box.
signature huh? *grabs pen*
x__I_like_pie__
www.vincepoops.com

jet192
Registered User
Posts: 52
Joined: Sun Aug 03, 2003 7:25 pm

Post by jet192 » Fri Oct 10, 2003 6:04 pm

maybe you should check out RustyDragons quick reply mod.. you can get it here http://www.phpbbhacks.com/viewhack.php?id=586

it has quote, emoticons, sig options, and a Notify me of reply option.


click the Veiw demo link to see what it looks like using subsilver. I use this one on my Sheri Moon site.. it works great on the 3 styles i use there.

Kendjin
Registered User
Posts: 375
Joined: Mon Sep 22, 2003 2:12 pm
Location: UK
Contact:

Post by Kendjin » Fri Oct 10, 2003 6:06 pm

Interesting, almost what I was looking for, except I think quick reply, should just be...

Message Input box, the 4 tickboxes and preview submit button.
My Avatar should say: I WANT YOU!!! to leave me alone.
But he's wearing a crimbo hat ^_^
A_Jelly_Doughnut is my idol ^-^

jet192
Registered User
Posts: 52
Joined: Sun Aug 03, 2003 7:25 pm

Post by jet192 » Fri Oct 10, 2003 6:15 pm

you can remove the smiles.. theres an option in the code if you set it to 0 there wont be any smiles.. the smiles annoy me on the quick reply.. but my users like them.. the quote button shouldnt be to hard to take out..

Kendjin
Registered User
Posts: 375
Joined: Mon Sep 22, 2003 2:12 pm
Location: UK
Contact:

Post by Kendjin » Fri Oct 10, 2003 6:23 pm

2.0.6 Compatible? or don't you know, I'll give it a crack and See..
My Avatar should say: I WANT YOU!!! to leave me alone.
But he's wearing a crimbo hat ^_^
A_Jelly_Doughnut is my idol ^-^

jet192
Registered User
Posts: 52
Joined: Sun Aug 03, 2003 7:25 pm

Post by jet192 » Fri Oct 10, 2003 6:27 pm

sure is.. im using 2.0.6

i also found in the .tpl where you can change the size of the text box and cosmetic changes like that.

Kendjin
Registered User
Posts: 375
Joined: Mon Sep 22, 2003 2:12 pm
Location: UK
Contact:

Post by Kendjin » Fri Oct 10, 2003 6:37 pm

hmm I tried it and it gave a few conflicts, but not this MOD's fault, you see my nicknames are links, so it disrupted the code for it..
My Avatar should say: I WANT YOU!!! to leave me alone.
But he's wearing a crimbo hat ^_^
A_Jelly_Doughnut is my idol ^-^

jet192
Registered User
Posts: 52
Joined: Sun Aug 03, 2003 7:25 pm

Post by jet192 » Fri Oct 10, 2003 6:39 pm

that sucks.. ill remember not to install that mod then

Post Reply

Return to “[2.0.x] MOD Requests”