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 1.2.5 (https://vborg.vbsupport.ru/showthread.php?t=4405)

12-17-2000 09:17 AM

Code:

if ($table=="privatercvd") {
    $messages = $DB_site->query("SELECT msgid,toid,fromid,title,UNIX_TIMESTAMP(datetime) AS datetime,iconid,repliedto FROM $table WH
  } elseif ($table=="privatesent") {
  $messages = $DB_site->query("SELECT msgid,toid,fromid,title,UNIX_TIMESTAMP(datetime) AS datetime,iconid FROM $table WHERE fromid
  }
  if ($messages) {
  //parse each message
  while ($message=$DB_site->fetch_array($messages)) {
    $fromid = trim($message[fromid]);
    if ($ignore[$fromid]) {
      continue;
    }
    $fromuser = $DB_site->query_first("SELECT username FROM user WHERE userid=$fromid");
    $from = stripslashes(trim($fromuser[username]));
    $toid = trim($message[toid]);
    $touser = $DB_site->query_first("SELECT username FROM user WHERE userid=$toid");
    if ($table=="privatesent") {
      $from = trim($touser[username]);

I have just read through the code briefly... and have a few suggestions:
1) The part where we want to get the name of $fromuser is a new query, so the number of queries fired will be proportional to the number of PM a person gets, why not do a join ?
2) the second part, to find the $touser, afaik, this field is useful if we are at the SentItems folder? So if we are else where, those queries fired are just wasting CPU cycles?

just my 2 cents..

12-24-2000 11:36 AM

Hey,
cool hack :)
i'm using vb v1.1.3 :(

annybody has the instructions for v1.1.3 ?

becuz...
i can't find in the showthread.php:
Code:

$posts=$DB_site->query("SELECT post.dateline as dateline,post.postid as postid,post.pagetext as pagetext,
                              post.allowsmilie as allowsmilie,post.signature AS showsignature,post.title as title,
                              post.ipaddress as ipaddress,post.iconid as iconid,post.username as fakename,
                              post.userid as userid,
                              user.userid as userid,user.email as email,user.username as username,
                              user.usertitle as usertitle,user.signature as signature,user.showemail as showemail,
                              user.homepage as homepage,user.icq as icq,user.aim as aim,user.yahoo as yahoo,
                              user.joindate as joindate,user.posts as posts

only this looks like it
Code:

$posts=$DB_site->query("SELECT dateline,postid,pagetext,allowsmilie,signature AS showsignature,title,ipaddress,iconid,username,userid FROM post WHERE threadid=$threadid AND visible=1 ORDER BY dateline $postorder LIMIT $limitlower,$perpage");
please annybody help me.. thnx

12-24-2000 11:38 AM

i also cant find $userinfo=$post; in showthread.php :(

12-24-2000 01:01 PM

Why not upgrade?

12-24-2000 01:04 PM

because i installed allready a lot of hacks :(

12-26-2000 01:57 AM

Hi everyone,,

Pleas help me 24 hours only from installing PM . And now my forums not work :( .

It is gaive me this messag :


There seems to have been a slight problem with the database. Please try again by pressing the refresh button in your browser.

An E-Mail has been dispatched to our Technical Staff, who you can also contact if the problem persists.

We apologise for any inconvenience.







So PLEAS Any body can help :(:( .

12-26-2000 02:12 AM

Error message is... I dunno, usually... REQUIRED! :)

12-26-2000 02:29 AM

Ed Sullivan

Quote:

Error message is... I dunno, usually... REQUIRED!

Ed, Pleas I cant understand , Now 4 hours not work .

what can i do now to solve this ? :(

12-26-2000 02:06 PM

You need to tell me the actual error message you're getting. Not just that cover. Paste the email here or view the page source and you'll see it.

12-26-2000 02:17 PM

Ed , there is no email sent to me .

Because (Technical Staff,) Not linkting to any email .

if you know where i have to but my email .

Thank you Ed ,


All times are GMT. The time now is 08:33 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.01087 seconds
  • Memory Usage 1,738KB
  • 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
  • (3)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