Go Back   vb.org Archive > vBulletin Modifications > Archive > vB.org Archives > vBulletin 2.x > vBulletin 2.x Full Releases
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools
Details »»

Version: 1.00, by Admin (Coder) Admin is offline
Developer Last Online: Nov 2024 Show Printable Version Email this Page

Version: 2.3.x Rating:
Released: 01-28-2002 Last Update: Never Installs: 1206
 
No support by the author.

Here's an easy one, it barely took 4 minutes to do. :china:
This hack will add a quick replying box at the bottom of all threads, only if the user has permission to reply, so when you need to reply to something real quickly you don't need to click the Post Reply button and wait for the page to load.

Instructions are in the attached .txt file, and if you want a demo... just look below.

NOTE: For the vB 2.3.2 version please see this post.

Extras:
  • If you want users who have the Use Email Notification option ON, to automatically subscribe to threads they reply to with this hack, see this post.
  • If you want to add an option for each user to turn this feature on and off, please see this post.
  • If you want smilies in your quick reply box please see this post.

Show Your Support

  • This modification may not be copied, reproduced or published elsewhere without author's permission.

Comments
  #512  
Old 07-19-2002, 01:32 PM
2600 2600 is offline
 
Join Date: Jul 2002
Posts: 5
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Never mind all sorted now and ive marked as installed! Great hack thanks!

2600
Reply With Quote
  #513  
Old 07-22-2002, 07:06 PM
Darth Cow's Avatar
Darth Cow Darth Cow is offline
 
Join Date: Nov 2001
Posts: 61
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I've got a modification that I wrote for my forums that allows users to turn the quick reply box on/off in their profile. If anyone's interesting, let me know, because otherwise I won't bother .
Reply With Quote
  #514  
Old 07-22-2002, 07:21 PM
James Cridland James Cridland is offline
 
Join Date: Nov 2001
Location: London, UK
Posts: 121
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I'm very interesting, and also very interested in this hack.

(Actually, I'm quite boring.)
Reply With Quote
  #515  
Old 07-22-2002, 08:54 PM
Boofo's Avatar
Boofo Boofo is offline
 
Join Date: Mar 2002
Location: Des Moines, IA (USA)
Posts: 15,776
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I want to be mature about this so...gimme, gimme, gimme, pweez!

Quote:
Originally posted by Darth Cow
I've got a modification that I wrote for my forums that allows users to turn the quick reply box on/off in their profile. If anyone's interesting, let me know, because otherwise I won't bother .
Reply With Quote
  #516  
Old 07-22-2002, 10:22 PM
Darth Cow's Avatar
Darth Cow Darth Cow is offline
 
Join Date: Nov 2001
Posts: 61
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Since I already have two requests...

First, run this database query:

Code:
ALTER TABLE user ADD showquickreply tinyint(1) DEFAULT '1' not null AFTER nosessionhash
EDIT: Corrected it to "AFTER nosessionhash" (I forgot I was basing the location after another hack I installed )

That will set the default to show the quick reply - changing "DEFAULT '1'" to "DEFAULT '0'" should set the default to no display.

Make a new template "modifyoptions_showquickreply" with the following contents:

Code:
<tr>
	<td bgcolor="#13486D"><normalfont><b>Show Quick Reply Box?</b></normalfont><br>
	<smallfont>Disabling this option will hide the quick reply boxes at the end of
each thread. You can still reply by clicking on "Post Reply".</smallfont></td>
	<td bgcolor="#13486D"><normalfont>
		<input type="radio" name="showquickreply" value="yes" $showquickreplychecked> yes
		<input type="radio" name="showquickreply" value="no" $showquickreplynotchecked> no
	</normalfont></td>
</tr>
Now, in member.php, after:

PHP Code:
  if ($bbuserinfo[nosessionhash]) {
    
$nosessionhashchecked="checked";
    
$nosessionhashnotchecked="";
  } else {
    
$nosessionhashchecked="";
    
$nosessionhashnotchecked="checked";
  } 
Add:

PHP Code:
// Show Quick Reply Option
  
if ($bbuserinfo[showquickreply]) {
    
$showquickreplychecked="checked";
    
$showquickreplynotchecked="";
  } else {
    
$showquickreplychecked="";
    
$showquickreplynotchecked="checked";
  }
// Show Quick Reply Option 
Still in member.php, before:

PHP Code:
  eval("dooutput(\"".gettemplate("modifyoptions")."\");");
}

// ############################### start update options ############################### 
Add:

PHP Code:
// Show Quick Reply Option
  
eval("\$showquickreplyoption = \"".gettemplate("modifyoptions_showquickreply")."\";");
// Show Quick Reply Option 
EDIT: Forgot this step at first, but here it is . In member.php after:

In member.php, after:

PHP Code:
  $cookieuser=iif($cookieuser=="yes",1,0);
  
$nosessionhash=iif($nosessionhash=="yes",1,0); 
Add:

PHP Code:
// Show Quick Reply Option
  
$showquickreply=iif($showquickreply=="yes",1,0);
// Show Quick Reply Option 
Still in member.php, find:

PHP Code:
  $DB_site->query("UPDATE user
                   SET "
.$updatestyles."adminemail='$adminemail',
                      showemail='
$showemail',invisible='$invisible',cookieuser='$cookieuser',
                      maxposts='"
.addslashes($umaxposts)."',daysprune='".addslashes($prunedays)."',
                      timezoneoffset='"
.addslashes($timezoneoffset)."',emailnotification='$emailnotification',
                      startofweek='"
.addslashes($startofweek)."',options='$options',receivepm='$receivepm',
                      emailonpm='
$emailonpm',pmpopup='$pmpopup',usergroupid='$bbuserinfo[usergroupid]',
                      nosessionhash='
$nosessionhash
Add (continuing previous line):
Code:
,showquickreply='$showquickreply'
Finally, in showthread.php, after:

PHP Code:
} elseif (!$thread['open'] and !ismoderator($thread['forumid'],'canopenclose')) {
    
$replybox=''
(Note: you'll have to install the regular quick reply hack first to find this)

Add:
PHP Code:
} elseif ($bbuserinfo['showquickreply']==0) {
    
$replybox=''
EDIT: One final step I forgot:

Edit the modifyoptions template. After the following code:

Code:
<!-- *** -->
<tr>
	<td bgcolor="#1D6AA0" colspan="2"><normalfont color="#EEEEFF"><b>Thread View Options</b></normalfont></td>
</tr>
<!-- *** -->
Add:

Code:
$showquickreplyoption
There, that should do the trick . If you have any trouble or can't get it to work, let me know.
Reply With Quote
  #517  
Old 07-23-2002, 08:38 AM
Sweet Evil Sweet Evil is offline
 
Join Date: Nov 2001
Posts: 57
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

vB 2.2.6
Been trying to add the smilies to this with no luck...
I tried $vbcode_smilies as in the new reply,etc.. but it is not working. Anyone know the code?

Thanks,
Reply With Quote
  #518  
Old 07-23-2002, 11:00 PM
Boofo's Avatar
Boofo Boofo is offline
 
Join Date: Mar 2002
Location: Des Moines, IA (USA)
Posts: 15,776
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

To add smilies to the quick reply box:

Add this line:

PHP Code:
$clickysmilies getclickysmilies(); 
to showthread.php right after this:

PHP Code:
$textareacols gettextareawidth(); 
then use $clickysmilies in the showthread_quickreply template to add the box with the smilies in it, but you will also need to add these two lines:

PHP Code:
<script language="Javascript" src="vbcode.js"></script>
<
script language="Javascript" src="vbcode_language.js"></script
to the template right after the <form> tag. That should work.
Reply With Quote
  #519  
Old 07-26-2002, 05:35 PM
Kiraly Kiraly is offline
 
Join Date: Jul 2002
Location: Italia - Puglia
Posts: 24
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Parse error: parse error, unexpected '}' in c:\programmi\easyphp\www\upload\showthread.php on line 94

Reply With Quote
  #520  
Old 07-26-2002, 08:03 PM
Boofo's Avatar
Boofo Boofo is offline
 
Join Date: Mar 2002
Location: Des Moines, IA (USA)
Posts: 15,776
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Post the lines 89 to 99 here and let us look at it.

Quote:
Originally posted by Kiraly
Parse error: parse error, unexpected '}' in c:\programmi\easyphp\www\upload\showthread.php on line 94

Reply With Quote
  #521  
Old 07-26-2002, 08:55 PM
Kiraly Kiraly is offline
 
Join Date: Jul 2002
Location: Italia - Puglia
Posts: 24
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally posted by Boofo
Post the lines 89 to 99 here and let us look at it.

line? how can i see this line? in the notepad?
Reply With Quote
  #522  
Old 07-26-2002, 09:13 PM
Boofo's Avatar
Boofo Boofo is offline
 
Join Date: Mar 2002
Location: Des Moines, IA (USA)
Posts: 15,776
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Yes. Take the 5 lines above it to the 5 lines below the error and post all of those.

Quote:
Originally posted by Kiraly


line? how can i see this line? in the notepad?
Reply With Quote
  #523  
Old 07-27-2002, 08:05 AM
Kiraly Kiraly is offline
 
Join Date: Jul 2002
Location: Italia - Puglia
Posts: 24
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

$post=$DB_site->query_first("
SELECT
post.*,post.username AS postusername,post.ipaddress AS ip,user.*,userfield.*,".iif($forum[allowicons],'icon.title as icontitle,icon.iconpath,','')."
attachment.attachmentid,attachment.filename,attach ment.visible AS attachmentvisible,attachment.counter
".iif($avatarenabled,",avatar.avatarpath,NOT ISNULL(customavatar.avatardata) AS hascustomavatar,customavatar.dateline AS avatardateline","")."
FROM post
".iif($forum[allowicons],'LEFT JOIN icon ON icon.iconid=post.iconid','')."
LEFT JOIN user ON user.userid=post.userid
LEFT JOIN userfield ON userfield.userid=user.userid
".iif ($avatarenabled,"LEFT JOIN avatar ON avatar.avatarid=user.avatarid
LEFT JOIN customavatar ON customavatar.userid=user.userid","")."
LEFT JOIN attachment ON attachment.attachmentid=post.attachmentid
WHERE post.postid = '$postid'
");

if (!$getperms['cangetattachment']) {
$viewattachedimages=0;
}

$postbits = getpostbit($post);

updateuserforum($thread['forumid']);

eval("dooutput(\"".gettemplate("showpost")."\");") ;
exit;
}
Reply With Quote
  #524  
Old 07-27-2002, 08:20 AM
Boofo's Avatar
Boofo Boofo is offline
 
Join Date: Mar 2002
Location: Des Moines, IA (USA)
Posts: 15,776
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Which line is the line with the error in it (line 94, I think)?
Reply With Quote
  #525  
Old 07-27-2002, 08:29 AM
Kiraly Kiraly is offline
 
Join Date: Jul 2002
Location: Italia - Puglia
Posts: 24
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

LEFT JOIN customavatar ON customavatar.userid=user.userid","")."
Reply With Quote
  #526  
Old 07-27-2002, 08:35 AM
Boofo's Avatar
Boofo Boofo is offline
 
Join Date: Mar 2002
Location: Des Moines, IA (USA)
Posts: 15,776
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Try changing this:

PHP Code:
eval("dooutput(\"".gettemplate("showpost")."\");");
exit;

to this:

PHP Code:
eval("dooutput(\"".gettemplate("showpost")."\");");
exit; 
and let me know if it works. If it doesn't, make sure you put the code back as it was and we will go from there.
Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 08:50 PM.


Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2024, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.10790 seconds
  • Memory Usage 2,404KB
  • Queries Executed 30 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)ad_showthread_beforeqr
  • (5)bbcode_code
  • (14)bbcode_php
  • (4)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)modsystem_post
  • (1)navbar
  • (6)navbar_link
  • (120)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (3)pagenav_pagelinkrel
  • (16)post_thanks_box
  • (16)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (16)post_thanks_postbit_info
  • (15)postbit
  • (16)postbit_onlinestatus
  • (16)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open
  • (1)tagbit_wrapper 

Phrase Groups Available:
  • global
  • inlinemod
  • postbit
  • posting
  • reputationlevel
  • showthread
Included Files:
  • ./showthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_post_thanks.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • showthread_start
  • showthread_getinfo
  • forumjump
  • showthread_post_start
  • showthread_query_postids
  • showthread_query
  • bbcode_fetch_tags
  • bbcode_create
  • showthread_postbit_create
  • postbit_factory
  • postbit_display_start
  • post_thanks_function_post_thanks_off_start
  • post_thanks_function_post_thanks_off_end
  • post_thanks_function_fetch_thanks_start
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • fetch_musername
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • pagenav_page
  • pagenav_complete
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete