Go Back   vb.org Archive > vBulletin Modifications > Archive > vB.org Archives > vBulletin 2.x > vBulletin 2.x Full Releases

Reply
 
Thread Tools
Private Text Message Hack v1.0 Details »»
Private Text Message Hack v1.0
Version: 1.00, by g-force2k2 g-force2k2 is offline
Developer Last Online: May 2008 Show Printable Version Email this Page

Version: 2.2.x Rating:
Released: 08-17-2002 Last Update: Never Installs: 19
 
No support by the author.

As requested [ Here ]

Please download the fixed attachment located [ Here ]

If you've downloaded this hack before the redownload it or make the changes below... else the hack won't work... that should be it

Unfortunately FireFly didn't have the time to make the hack so i took it up on my own Hope that you enjoy it... here's the breakdown... screenshots will be included below

Private Text Hack v1.0
Hack created g-force2k2 Sunday August 18th, 2002
vbulletin 2.2.6
Please don't edit this hack if you need any assistance refer to the thread.
If you have any problems please refer to the thread.
// ++++++++++++++

To Do
// ++++++++++++++
Queries to Run (6)
File Modifications (28)
newreply.php (8)
showthread.php (6)
editpost.php (8)
admin/functions.php (2)
admin/usergroup.php (4)
Templates to Add (8)
Templats to Edit (3)

What does this hack do?
// ++++++++++++++
It allows your users to private text each other within a post.
It still maintains a regular post. but allows an option to private text other users.
You can choose which usergroupcs can add private text messages and which groups can see them.
But unless a usergroup is allowed to view no other user will be able to view it except the user recieving and the user posting.
Enjoy this hack It's really a good addition to keep things smart.
The usergroups options can be edited in the admin cp usergroup.php
And the private text length can also edited in the vbulletin options in admin cp under thread options.
The private text messages work with bbcode... smilies... and disables html etc... same as a regular message would work.
Also maintains the same image count... so if you have your image set at 5 per post and the user tries 3 in a post and 3 in the private text message they will get the images error
The private text messages can be edited the same way as a post, but when quoting they're bypassed.
Hopefully you'll enjoy this hack as much as i did making it If you like it please click on the install thanks [ g-force2k2 ]

For editpost.php change view this post

https://vborg.vbsupport.ru/showthrea...518#post287518

For another editpost.php change view this post

https://vborg.vbsupport.ru/showthrea...633#post287633

For enabling users to edit their own private text messages view this post

https://vborg.vbsupport.ru/showthrea...651#post287651

g-force2k2

Show Your Support

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

Comments
  #112  
Old 08-20-2002, 04:26 AM
Sho Sho is offline
 
Join Date: Nov 2001
Location: Berlin, Germany
Posts: 155
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

g-force2k2, Boofo considers it a problem that you can't edit a post to add a private text. I know you intended it to work this way - anyway, I'm with Boofo on this one. Give us!

Schorsch, on the other hand, considers it a problem that you can't edit a private text after posting. Again, you intended it to work this way. That's okay with me.
Reply With Quote
  #113  
Old 08-20-2002, 04:27 AM
Boofo's Avatar
Boofo Boofo is offline
 
Join Date: Mar 2002
Location: Des Moines, IA (USA)
Posts: 15,776
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

g-force2k2, here you go. It is the excat same template in your install file.

Code:
<!-- private text hack [ g-force2k2 ] -->
<tr><td bgcolor="{secondaltcolor}" valign="top"><normalfont><b>Private Text Options:</b></normalfont><br><smallfont>Maximium Characters: $PTMlength</smallfont></td>
<td bgcolor="{secondaltcolor}"><smallfont><input type="checkbox" name="dopriv" value="no" $dopriv><b>Add a private text message to the post?</b><br><input type="text" class="bginput" name="privuser" size="20" maxlength="50" value="$postinfo[privuser]"> <b>Username to send private text to?</b><br><textarea name="privmsg" rows="10" cols="$textareacols" onChange=getActiveText(this) onclick=getActiveText(this)>$postinfo[privmsg]</textarea></td></tr>
<!-- private text hack [ g-force2k2 ] -->
Jashugan, when I go into edit mode and change anything in the private text message, when I go to save it, it is the exact same as it was before I edited it. It doesn't take any changes I made to the original private text message..
Reply With Quote
  #114  
Old 08-20-2002, 04:28 AM
g-force2k2 g-force2k2 is offline
 
Join Date: Mar 2002
Location: Everywhere you wanna be..
Posts: 1,608
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

// +++++++ Addon for allowing post owner to edit their own private text message +++++++
open editpost.php (2)

find: (1)

PHP Code:
// +++++++ Private Text Hack [ g-force2k2 ] +++++++
if($getperms[canviewprivtxt]) {
  eval(
"\$privtxtedit = \"".gettemplate("editpost_privtxt")."\";");
} else {
  
$privtxtedit "";
}
// +++++++ Private Text Hack [ g-force2k2 ] +++++++ 
replace it with:

PHP Code:
// +++++++ Private Text Hack [ g-force2k2 ] +++++++
if(($getperms[canviewprivtxt]) OR ($postinfo[username] == "$bbuserinfo[username]")) {
  eval(
"\$privtxtedit = \"".gettemplate("editpost_privtxt")."\";");
} else {
  
$privtxtedit "";
}
// +++++++ Private Text Hack [ g-force2k2 ] +++++++ 
find: (2)

PHP Code:
// +++++++ Private Text Hack [ g-force2k2 ] +++++++
if($getperms[canviewprivtxt]) {
  
$DB_site->query("UPDATE post SET title='".addslashes(htmlspecialchars($title))."',pagetext='".addslashes($message)."',allowsmilie='$allowsmilie',showsignature='$signature',iconid='$iconid'$editedbysql$attachmentsql,dopriv=$dopriv,privuser='".addslashes($privuser)."',privmsg='".addslashes($privmsg)."' WHERE postid='$postid'");
} else {
  
$DB_site->query("UPDATE post SET title='".addslashes(htmlspecialchars($title))."',pagetext='".addslashes($message)."',allowsmilie='$allowsmilie',showsignature='$signature',iconid='$iconid'$editedbysql$attachmentsql WHERE postid='$postid'");
}
// +++++++ Private Text Hack [ g-force2k2 ] +++++++ 
replace with:

PHP Code:
// +++++++ Private Text Hack [ g-force2k2 ] +++++++
if(($getperms[canviewprivtxt]) OR ($postinfo[username] == "$bbuserinfo[username]")) {
  
$DB_site->query("UPDATE post SET title='".addslashes(htmlspecialchars($title))."',pagetext='".addslashes($message)."',allowsmilie='$allowsmilie',showsignature='$signature',iconid='$iconid'$editedbysql$attachmentsql,dopriv=$dopriv,privuser='".addslashes($privuser)."',privmsg='".addslashes($privmsg)."' WHERE postid='$postid'");
} else {
  
$DB_site->query("UPDATE post SET title='".addslashes(htmlspecialchars($title))."',pagetext='".addslashes($message)."',allowsmilie='$allowsmilie',showsignature='$signature',iconid='$iconid'$editedbysql$attachmentsql WHERE postid='$postid'");
}
// +++++++ Private Text Hack [ g-force2k2 ] +++++++ 
There that should allow users to edit their own private txt messages...

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

Sho, you must have misubderstood me. I can edit a post to add private text, I just can't edit the private text after it is posted.

Quote:
Originally posted by Sho
g-force2k2, Boofo considers it a problem that you can't edit a post to add a private text. I know you intended it to work this way - anyway, I'm with Boofo on this one. Give us!

Schorsch, on the other hand, considers it a problem that you can't edit a private text after posting. Again, you intended it to work this way. That's okay with me.
Reply With Quote
  #116  
Old 08-20-2002, 04:29 AM
g-force2k2 g-force2k2 is offline
 
Join Date: Mar 2002
Location: Everywhere you wanna be..
Posts: 1,608
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Boofo try taking out the codes that you added in... the onchange and all then try and see if that works? thanks in advance...

g-force2k2
Reply With Quote
  #117  
Old 08-20-2002, 04:32 AM
Jashugan Jashugan is offline
 
Join Date: Aug 2002
Posts: 24
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally posted by Boofo
Jashugan, when I go into edit mode and change anything in the private text message, when I go to save it, it is the exact same as it was before I edited it. It doesn't take any changes I made to the original private text message..
Umm when you edit, are you using Admin access? Cuz I edit and save it without any problem with Admin access (g-force didnt add more group permission yet but soon) I change the private message or add few message and it come out normal.
Reply With Quote
  #118  
Old 08-20-2002, 04:37 AM
Sho Sho is offline
 
Join Date: Nov 2001
Location: Berlin, Germany
Posts: 155
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
There that should allow users to edit their own private txt messages...
Works!

Quote:
Sho, you must have misubderstood me. I can edit a post to add private text, I just can't edit the private text after it is posted.
Didn't work until now, now it works!

Sorry about the missunderstanding, Boofo.
Reply With Quote
  #119  
Old 08-20-2002, 04:43 AM
Boofo's Avatar
Boofo Boofo is offline
 
Join Date: Mar 2002
Location: Des Moines, IA (USA)
Posts: 15,776
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I t0ook the code out and it still doesn't allow me to edit a private text message. I can edit it, it just won't allow me to change it from the original on save.

Quote:
Originally posted by g-force2k2
Boofo try taking out the codes that you added in... the onchange and all then try and see if that works? thanks in advance...

g-force2k2
Reply With Quote
  #120  
Old 08-20-2002, 04:46 AM
Sho Sho is offline
 
Join Date: Nov 2001
Location: Berlin, Germany
Posts: 155
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally posted by Boofo
I t0ook the code out and it still doesn't allow me to edit a private text message. I can edit it, it just won't allow me to change it from the original on save.
Hm, it works here.

- With my own private texts.

- With other's private texts - after "Can view all private text messages" for my usergroup, of course.
Reply With Quote
  #121  
Old 08-20-2002, 04:46 AM
Boofo's Avatar
Boofo Boofo is offline
 
Join Date: Mar 2002
Location: Des Moines, IA (USA)
Posts: 15,776
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

g-force2k2, look at the code right above it in my editpost.php and see if maybe that is what is causing the problem. The Admin edit options.
Reply With Quote
Reply

Thread Tools

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 03:07 PM.


Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.04893 seconds
  • Memory Usage 2,341KB
  • Queries Executed 27 (?)
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
  • (1)bbcode_code
  • (4)bbcode_php
  • (6)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
  • (1)pagenav_pagelinkrel
  • (11)post_thanks_box
  • (11)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (11)post_thanks_postbit_info
  • (10)postbit
  • (11)postbit_onlinestatus
  • (11)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_postinfo_query
  • fetch_postinfo
  • 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