vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   Modification Graveyard (https://vborg.vbsupport.ru/forumdisplay.php?f=224)
-   -   Private Messages Enhancements - Read Your Members Private Messages (v1.2) (https://vborg.vbsupport.ru/showthread.php?t=66389)

patriotcow 11-30-2004 07:50 PM

Quote:

Originally Posted by 7thgenCivic.Com
i am getting a couple of errors at the top

PHP Code:

Warningarray_keys(): The first argument should be an array in /home/public_html/forums/admin/pm.php on line 156

Fatal error
Cannot create references to/from string offsets nor overloaded objects in /home/public_html/forums/admin/pm.php on line 158 


Are mods also allowed to read them?

I mean super modz

MotoUp 12-09-2004 02:24 PM

This won't make the PM show as unread for the user will it?

Viks 12-09-2004 11:57 PM

>>You have to be a super administrator to read private messages, this can be set within config.php

how can one do this... coz vB does not show up Super Administrators in usermanager!!

:ermm:

sorry for my ignorance.

Viks 12-10-2004 03:07 AM

:) its ok i figured it out!

however -
Quote:

Originally Posted by MotoUp
This won't make the PM show as unread for the user will it?

will it???

i guess i can test it! and post the reply here

Viks 12-10-2004 03:14 AM

Quote:

Originally Posted by MotoUp
This won't make the PM show as unread for the user will it?

if admin reads the message... i PM still shows as unred to user.

bold 12-15-2004 05:37 AM

Quote:

Originally Posted by 7thgenCivic.Com
i am getting a couple of errors at the top

PHP Code:

Warningarray_keys(): The first argument should be an array in /home/public_html/forums/admin/pm.php on line 156

Fatal error
Cannot create references to/from string offsets nor overloaded objects in /home/public_html/forums/admin/pm.php on line 158 


anyone find a fix for this yet?

trevelyn1015 12-15-2004 05:54 AM

i think it is unethical to read "private messages" of other people... landlords don't read their renter's mail...

bold 12-15-2004 08:35 AM

google does :P

StevenTN 12-15-2004 08:37 PM

My employer reads my email, and employers do have the legal right to read their employee's mail.

Plus, postal mail is legally protected in a way that e-mail is not, and PMs are there as a convenience, not a secure way for communication.

trevelyn1015 12-15-2004 11:46 PM

i see your point...

StevenTN 12-16-2004 05:15 AM

I just finally added the hack... and so my admins don't have to mess around with typing in URLs, I added a crude search form to the Admin CP home...

I've also hacked my config.php and pm.php so there's now a $canviewpms variable and it will regard that instead of the $superadministrators variable.

Find this...
PHP Code:

   if (can_administer('canadminusers'))
   {
       
print_label_row($vbphrase['quick_user_finder'], '
           <form action="user.php" method="post" style="display:inline">
           <input type="hidden" name="s" value="' 
$session['sessionhash'] . '" />
           <input type="hidden" name="do" value="find" />
         <input type="text" class="bginput" name="user[username]" size="30" tabindex="1" />
         <input type="submit" value=" ' 
$vbphrase['find'] . ' " class="button" tabindex="1" />
         <input type="submit" class="button" value="' 
$vbphrase['exact_match'] . '" tabindex="1" name="user[exact]" />
           </form>
           '
'''top'NULLfalse
       
);
   } 

And before the closing curly brace, add this...
PHP Code:

       print_label_row('Lookup PM (by userid)''
         <form action="/boards/admincp/pm.php" method="get" style="display:inline">
         <input type="text" class="bginput" name="userid" size="30" tabindex="1" />
         <input type="submit" value=" ' 
$vbphrase['find'] . ' " class="button" tabindex="1" />
           </form>
           '
'''top'NULLfalse
       
); 

The reason why I added it is a) we're covered in our ToS when it comes to these, b) I had a rather crude PM system when we had vB2.3.x, and c) We get complaints at least once or twice a month about abusive PMs, which is covered in point a.

If you want me to make this more viable (like have the vbphrase variable), let me know.

Mechanical Mind 12-18-2004 11:08 PM

* clicks install *

Not working for me.

Am I confused, all I did was upload it to admincp folder and try to reach the link via my web browser.

I got this message: the requested document is not found on this server.

Help!!!

StevenTN 12-18-2004 11:18 PM

What was the URL you tried? I'm willing to bet it might've been mistyped or put in the wrong area.

Mechanical Mind 12-18-2004 11:28 PM

Quote:

Originally Posted by StevenTN
What was the URL you tried? I'm willing to bet it might've been mistyped or put in the wrong area.

Well, I have renamed my adminCP folder. Could this have something to do with it? But I tried modifying the URL to include that. And I tried modifying the one instance of "admincp" to "my secret name".

I guess the real question is:
- What do I need to add/delete/modify since I have a renamed adminCP folder?

Samira 12-22-2004 06:15 PM

Is anyone else having problems reading messages with the Quote tags? I had a mod installed that altered the look of the quotes and I uninstalled that, but am having the same problem. Suggestions?

JD210 12-27-2004 09:06 AM

Installed it, but I get the following error at the top, plus it is showing that no PMs have been sent. I use 3.0.3.

Quote:

Warning: Call-time pass-by-reference has been deprecated - argument passed by value; If you would like to pass it by reference, modify the declaration of array_keys(). If you would like to enable call-time pass-by-reference, you can set allow_call_time_pass_reference to true in your INI file. However, future versions may not support this any longer. in /home2/www/******/forum/admincp/pm.php on line 156

Paul M 12-27-2004 09:55 AM

Quote:

Originally Posted by JD210
Installed it, but I get the following error at the top, plus it is showing that no PMs have been sent. I use 3.0.3.

Are you using php5 ?

JD210 12-27-2004 08:34 PM

No, PHP 4

TMAC 12-31-2004 09:44 PM

So does this work with version 3.03?

Thanks You

pco 01-01-2005 08:55 PM

Quote:

Originally Posted by Samira
Is anyone else having problems reading messages with the Quote tags? I had a mod installed that altered the look of the quotes and I uninstalled that, but am having the same problem. Suggestions?

in pm.php in function parse_pm_bbcode($bbcode) change at the end of the return line from this:

PHP Code:

,$vboptions['privallowbbcode'])); 

to this:

PHP Code:

,$vboptions['privallowbbcode'],1)); 

:)

Bison 01-02-2005 02:01 AM

Quote:

Originally Posted by BrentWilson
Warning: array_keys(): The first argument should be an array in /home/httpd/vhosts/mustang-forums.com/httpdocs/forums/admincp/pm.php on line 156

Anyone care to stop arguing and actually help fix this error? Someone has already asked about this one earlier

On Line 156:

Find:
Code:

$pm['receiver_key'] = array_keys(&$pm['receiver_raw']);
Change to this:
Code:

$pm['receiver_key'] = //array_keys(&$pm['receiver_raw']);

sim tech 01-25-2005 03:47 AM

I tried both mods on version 3.0.6 and they both work. The pm.php insert, where you have to enter the user number in the address line (takes about 5 seconds to install) and also the user.php mod described at:

https://vborg.vbsupport.ru/showpost....1&postcount=94

The use.php mod is a bit more admin friendly, but it would be better if a mod like this could be be displayed on the control panel's "Private Message Statistics" drop down menu... rather then the edit users menu.

Is this possible??

T3MEDIA 01-31-2005 12:06 PM

Quote:

Originally Posted by dethfire
this doesn't work for me, just times out

EXACTLY IS THERE ANYFIX PEOPLE
if you got it working what did you do.
CAN YOU AT LEAST SHOW THE OTHER USERS PLEASE?

Please and thank you.

T3MEDIA 01-31-2005 12:10 PM

Quote:

Originally Posted by StevenTN
I just finally added the hack... and so my admins don't have to mess around with typing in URLs, I added a crude search form to the Admin CP home...

I've also hacked my config.php and pm.php so there's now a $canviewpms variable and it will regard that instead of the $superadministrators variable.

Find this....

Would be nice if the search went thru notes for a specific word.

Battle_Ring 02-15-2005 10:05 PM

This dont work with 3.0.6???????

MAK-upl 02-17-2005 11:59 PM

Works on 3,0,6 - clicks instal

very good job

T3MEDIA 02-18-2005 08:14 PM

Quote:

Originally Posted by T3MEDIA
EXACTLY IS THERE ANYFIX PEOPLE
if you got it working what did you do.
CAN YOU AT LEAST SHOW THE OTHER USERS PLEASE?

Please and thank you.

bump

TCM 03-26-2005 06:16 AM

Nice hack, or revision, or whatever. I'm talking it over with my other admin, we may chose to install this hack. I have, in the past, read messages through PHPMyAdmin for harassment reasons, and this would make it easier. Maybe renaming it to Personal Messages instead, though.
Quote:

Originally Posted by T3MEDIA
bump

POSTING IN CAPS MAKES ME FEEL IMPORTANT

Trigunflame 03-26-2005 11:10 AM

I may completely rewrite this, and turn it into a full fledged hack, I believe there are quite a few more features that could be added.

clearchannel 03-26-2005 01:31 PM

Quote:

Originally Posted by TCM
Maybe renaming it to Personal Messages instead, though.
POSTING IN CAPS MAKES ME FEEL IMPORTANT

I am also giving this hack serious consideration. I would however, like to change the name from "private messages" to "Network Messages" the only draw back so far is there are many many templates to change.

Anyone have advice to offer as to a quick and easy method to change the private message reference to network message?

Trigunflame 03-26-2005 02:00 PM

Quote:

Originally Posted by clearchannel
I am also giving this hack serious consideration. I would however, like to change the name from "private messages" to "Network Messages" the only draw back so far is there are many many templates to change.

Anyone have advice to offer as to a quick and easy method to change the private message reference to network message?

You have a place in your control panel to modify Phrases for a reason :)

Antivirus 04-03-2005 01:53 AM

Quote:

Originally Posted by Bison
On Line 156:

Find:
Code:

$pm['receiver_key'] = array_keys(&$pm['receiver_raw']);
Change to this:
Code:

$pm['receiver_key'] = //array_keys(&$pm['receiver_raw']);

That does get rid of all "line 156 errors", but actually creates a new problem... now when viewing member's "sent items" mailbox for instance, the "sent to" column no longer shows the member name the PM was sent to. This is also the case when viewing the members "inbox" although in that case, it's rather obvious who's name the PM was sent to, as you're viewing all their PMs.

:(

GSX-Racing 05-16-2005 09:27 PM

Testing it.

Can you choose to view all rather than per/user.

topten 05-18-2005 12:43 AM

bloody great hack! Love it!

beansbaxter 06-19-2005 12:22 AM

doesnt work on 3.0.7

due for an update it looks like

ayhanaydogdu 06-23-2005 09:34 AM

Does not it work on vb 3,07? :(

COBRAws 06-23-2005 09:46 AM

Quote:

Originally Posted by Trigunflame
I may completely rewrite this, and turn it into a full fledged hack, I believe there are quite a few more features that could be added.

3.5 final =D

TruckMuddr 06-24-2005 12:28 AM

Works fine on my 3.0.7

xtreme-mobile 06-24-2005 07:59 PM

i get not authorized message edit the config etc

i put my user id in the supermoderator bit but it still says not authorized?

any ideas?

im using vb 3.0.7

TruckMuddr 06-24-2005 10:47 PM

If your not worried about other admins reading PM's just Find and remove this code.
Lines 41 -47
Code:

// User Is Not SuperAdmin
if (!in_array($bbuserinfo['userid'], preg_split('#\s*,\s*#s', $superadministrators, -1, PREG_SPLIT_NO_EMPTY)))
{
// Output Header/Message
print_cp_header('Your Not Authorized');
print_cp_message('You have to be a super administrator to read private messages, this can be set within config.php');
}


I'M ONLY SUGGESTING THE FOLLOWING CAUSE THERE IS SOMETHING WRONG WITH THE WAY YOURS INSTALLED, THIS IS PRETTY MUCH THE SAME THING AS BEFORE JUST NOT READING FROM CONFIG.PHP AND FOR ONLY ONE USER.


step 1:
Find code above and replace it with:
Code:

if ($bbuserinfo['userid'] == XX)
{

< REPLACE XX WITH YOUR USERID --- If you want more then one user then it should look like this if (($bbuserinfo['userid'] == XX) OR ($bbuserinfo['userid'] == XX)) >




step 2:
Find this:
Code:

/*======================================================================*\
|| This file is distributed through http://www.vBulletin.nl/
\*======================================================================*/

Above ADD:
Code:

}
else
{
// Output Header/Message
print_cp_header('Your Not Authorized');
print_cp_message('ENTER YOUR ERROR MESSAGE HERE');
}

Again as this may work, I would suggest finding what is wrong. Maybe Your Config.php is wrong someone. I've done it before.

Config.php should look something like this
Code:

// ****** SUPER ADMINISTRATORS ******
// The users specified below will have permission to access the administrator permissions
// page, which controls the permissions of other administrators
$superadministrators = 'X, X, X';

IF THIS VIOLATES SOMETHING THEN PLEASE DELETE THIS POST. JUST TRYIN TO HELP OUT.


All times are GMT. The time now is 04:17 AM.

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.01395 seconds
  • Memory Usage 1,855KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (9)bbcode_code_printable
  • (6)bbcode_php_printable
  • (17)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (40)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.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/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.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
  • printthread_start
  • pagenav_page
  • pagenav_complete
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete