vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   Member Archives (https://vborg.vbsupport.ru/forumdisplay.php?f=202)
-   -   [RELEASE] Private Messaging Hack (v0.9) !!!!!!! (https://vborg.vbsupport.ru/showthread.php?t=1095)

06-14-2000 01:16 PM

Thanks everyone!! This is a great hack and it was great to see such creative minds at work!! :D

06-14-2000 02:21 PM

RE: The Date Problem

Quite a simple fix actually, in private.php, find: (line 146)
Code:

$userinfo=$DB_site->query_first("SELECT userid,email,username,usertitle,signature,showemail,homepage,icq,aim,yahoo,UNIX_TIMESTAMP(joindate) AS  joindate,posts FROM user WHERE userid=$userid2");
Replace with:
Code:

$userinfo=$DB_site->query_first("SELECT userid,email,username,usertitle,signature,showemail,homepage,icq,aim,yahoo,joindate,posts FROM user WHERE userid=$userid2");
Can anyone else tell me if I'm the only person still running v1.1.1? Because if I am, there's no use in me adding a "version" switch...

06-14-2000 02:28 PM

RE: Profile Problem

Another REALLY simple fix, in private.php, (line 143) Find:
Code:

$userid2=$fromid;
Under it, add (for simplicity's sake):
Code:

$userid=$fromid;

06-14-2000 03:55 PM

Ok, another release - most (if not all) of the fixes included in v0.9.3 have been posted here, either by me or someone else.

However, there are a few things I want to address.

1. The index.php code has changed significantly:
Code:

  //PM HACK
  if ($bbusername) {
          $username = $bbusername;
          $pmcounta = $DB_site->query_first("SELECT COUNT(msgid) AS msgid FROM privatercvd WHERE toid=$bbuserid");
          $pmcount = $pmcounta[msgid];
          $newpmcounta = $DB_site->query_first("SELECT COUNT(msgid) AS msgid FROM privatercvd WHERE toid=$bbuserid AND UNIX_TIMESTAMP(datetime)>$bblastvisit");
          $newpmcount = $newpmcounta[msgid];
        if ($newpmcount == 0) {
                $lightbulb = 'images/off.gif';
        } else {
                $lightbulb = 'images/on.gif';
        }
        $lastsent = $DB_site->query_first("SELECT fromid,UNIX_TIMESTAMP(datetime) AS datetime FROM privatercvd WHERE toid=$bbuserid ORDER BY msgid DESC");
        if ($lastsent) {
                $lastid = trim($lastsent[fromid]);
                $lastdate=date($dateformat,$lastsent[datetime]+(($timeoffset+$bbtimezoneoffset)*3600));
                $lasttime=date($timeformat,$lastsent[datetime]+(($timeoffset+$bbtimezoneoffset)*3600));
                $lastsentuser = $DB_site->query_first("SELECT username FROM user WHERE userid=$lastid");
                $lastuser = htmlspecialchars($lastsentuser[username]);
        }
          eval("\$pminfo .= \"".gettemplate("pmloggedin")."\";");
  } else {
          eval("\$pminfo .= \"".gettemplate("pmloggedout")."\";");
  }
  //END PM HACK

2. pmloggedin changed pretty significantly too:
Code:

<TR bgcolor="{categorybackcolor}" id=cat><TD colspan=6>
<font color="{categoryfontcolor}" size=2><B>Private Messaging:</B></font></td>
</tr>

<tr bgcolor="{firstaltcolor}">
<td><img src="$lightbulb"></td>
<td colspan=5>
<smallfont><a href="private.php">Read them!</a>
<BR>$username - You have $pmcount private message(s) ($newpmcount new) -  Latest Message from <a href="member.php?action=getinfo&userid=$lastid">$lastuser</a></smallfont></td>
</tr>

Also, I suggest EVERYONE!! snag the newest private.php, since it contains all the bugfixes I know of :)

~~~Current Version: v0.9.3 :D

BTW, Me2Be, yes that's better... Women...

06-14-2000 05:25 PM

2 more bugs...

When you go to delete a post and hit cancel the post still gets deleted.

Even if you don't check the "delete" check box you can hit delete and the post is removed.

06-14-2000 07:52 PM

I updated to the new version and i'm now unable to log in with the username 'Craig Antill' but I am able to with the username 'Administrator' - I presume it's because it's a single word with no spaces ? This has only happened since I updated - here is the error I get:

Quote:

Database error in vBulletin: Invalid SQL: SELECT username FROM user WHERE userid=
mysql error: You have an error in your SQL syntax near '' at line 1
mysql error number: 1064
Date: Thursday 15th of June 2000 09:32:41 AM
Script: /forum/index.php
Referer:
I have just been and double checked that I followed the instructions correctly - I did - does anyone else have this problem ? If not, what could it be ?

06-14-2000 08:05 PM

OK, found the problem - the instructions in the latest .zip don't seem to match the code you give above. I've added the above code in place of that in the zip and all is fine and dandy.

You do like to panic me, don't you ?!

06-14-2000 08:28 PM

Hey! Just noticed the time and date features - excellent! I've now setup pmloggedin exactly like forumbit with full details of the last post - time, date & who made it - as well as the lightbulbs - great work fellas

06-14-2000 10:08 PM

I was curious to see what icon people were choosing.. and of those I checked, they were quite varied in their selection. Our poor hack author Ed has a dark (black?) background and you couldn't read the icon text. So here for our esteemed hack are the icons with white text...

http://www.wakeamerica.com/forums/im...m2_onblack.gif
http://www.wakeamerica.com/forums/im...m3_onblack.gif
http://www.wakeamerica.com/forums/im...m4_onblack.gif

[Edited by Wake America on 06-15-2000 at 07:10 AM]

06-15-2000 01:19 AM

Craig - Sorry about that, I knew I had that typo at one time, but I thought I fixed it :(

Rick - Fixed both bugs you mentioned (one was just a typo in makeprivtables.php)

I suggest everyone re-update their private.php :D

WakeAmerica - Thanks! I never got around to making the white text version.


All times are GMT. The time now is 05:06 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.01308 seconds
  • Memory Usage 1,749KB
  • 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
  • (6)bbcode_code_printable
  • (1)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
  • (10)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