vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 2.x Full Releases (https://vborg.vbsupport.ru/forumdisplay.php?f=4)
-   -   Last post on forum home, working version (https://vborg.vbsupport.ru/showthread.php?t=28561)

Alien 09-23-2001 02:23 PM

Hey..

Yeah, I checked my index.php file and it does contain that code below.. I see it is working well on your forum, so it must just be something minor somehow...

Hmmm. :)

Quote:

Originally posted by PPN
i just posted the topic identical to what you used, make sure in index.php that
PHP Code:

          $forum['lasttitle']=unhtmlspecialchars($forum['lasttitle']); 

was added when you were pasting information. Either that or I have missed something else out in the hack, which i hope i haven't.


dxb 11-04-2001 01:50 AM

PPN any updates for this hack

Scott MacVicar 11-04-2001 09:42 AM

updated to work with 2.2.0 there was a small difference with the functions.php, it was just a change in the way the query was run, the update file has been updated to accomodate this.

I also adjust what i presumed was the problem that Alien was experiencing.

Thomas P 11-04-2001 10:27 AM

Hi,

does it let you edit & update the length of the last title through the cp?
Does it support different settings depending on the forum (on/off & length)?
Thanks,
-Tom

dxb 11-04-2001 11:21 PM

hi there PPN

I just downloaded your file and I cant find this

PHP Code:


if ($lastposts['lastpost']) {
    if (
$lastposts['lastpost']>$lastpost or $lastposts['lastpost']<$currentlastpost) {
      
$lastposts=$DB_site->query_first("SELECT lastpost,lastposter FROM thread WHERE lastpost='$lastposts[lastpost]'");
                        
$lastpost=$lastposts['lastpost'];
                        
$lastposter=$lastposts['lastposter'];
                }
  } 

the closes i was able to find is

PHP Code:


if ($lastposts['lastpost']>$lastpost) {
        
$lastposts=$DB_site->query_first("SELECT lastpost,lastposter FROM thread WHERE lastpost='$lastposts[lastpost]'");
        
$lastpost=$lastposts['lastpost'];
        
$lastposter=$lastposts['lastposter'];
    } 


and also this query seems to be changed a bit

PHP Code:


$DB_site
->query("UPDATE forum SET replycount='$numberposts',threadcount='$numberthreads',lastpost='$lastpost',lastposter='".addslashes(htmlspecialchars($lastposter))."' WHERE forumid='$forumid'"); 

to this


PHP Code:


$DB_site
->query("UPDATE forum SET replycount='$numberposts',threadcount='$numberthreads$lastpostquery WHERE forumid='$forumid'"); 


I tried to work on them but with no success :(

Scott MacVicar 11-05-2001 06:28 AM

Ok instructions updated.

PHP Code:

then look for

      
$lastposts=$DB_site->query_first("SELECT lastpost,lastposter FROM thread WHERE 

lastpost='
$lastposts[lastpost]'");
                        
$lastpost=$lastposts['lastpost'];
                        
$lastposter=$lastposts['lastposter'];

change to

      $lastposts
=$DB_site->query_first("SELECT lastpost,lastposter,title FROM thread WHERE 

lastpost='
$lastposts[lastpost]'");
                        
$lastpost=$lastposts['lastpost'];
                        
$lastposter=$lastposts['lastposter'];
                        
$lasttitle=$lastposts['title'];

-------
FOR 
VB 2.0.x

on line 1498 look 
for
  
$DB_site->query("UPDATE forum SET 

replycount='
$numberposts',threadcount='$numberthreads',lastpost='$lastpost',lastposter='".addslashes(htmlspecialc

hars
($lastposter))."' WHERE forumid='$forumid'"); 

change it to

  $DB_site
->query("UPDATE forum SET 

replycount='
$numberposts',threadcount='$numberthreads',lastpost='$lastpost',lastposter='".addslashes(htmlspecialc

hars
($lastposter))."',lasttitle='".addslashes($lasttitle)."' WHERE forumid='$forumid'"); 

FOR 
VB 2.2.x

look 
for
        if (
$lastpost!=$currentlastpost) {
                
$lastpostquery=",lastpost='$lastpost',lastposter='".addslashes($lastposter)."'";
        } else {
                
$lastpostquery="";
        }

change to

        
if ($lastpost!=$currentlastpost) {
                

$lastpostquery=",lastpost='$lastpost',lastposter='".addslashes($lastposter)."',lasttitle='".addslashes($lasttitle)."'";
        } else {
                
$lastpostquery="";
        } 


Thomas P 11-05-2001 08:54 AM

Quote:

Originally posted by Thomas P
Hi,

does it let you edit & update the length of the last title through the cp?
Does it support different settings depending on the forum (on/off & length)?
Thanks,
-Tom

I guess this means "no"... well is there any possibility to change the length of the last title appearing?
-Tom

dxb 11-05-2001 10:35 AM

Sorry PPN I got lost here ... the instruction file in the first post of this hack is still not updated ....

and million thanks for your :)

Scott MacVicar 11-05-2001 01:49 PM

It won't let me update the file or add a new one i keep getting this error.

Will bring it up to FireFly

Scott MacVicar 11-05-2001 02:15 PM

yep its been updated, Firefly made sure it was now...

I don't want to post the contents of the file but try making sure its not your cache causing problems.


All times are GMT. The time now is 09:20 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.01405 seconds
  • Memory Usage 1,774KB
  • 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_php_printable
  • (2)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (1)pagenav_pagelinkrel
  • (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