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)
-   -   vbArchive - Search Engine Indexer for vBulletin (https://vborg.vbsupport.ru/showthread.php?t=47667)

TECK 01-15-2003 03:20 AM

The fix for [HIGH]online.php[/HIGH] file, to display nice links, is below.
There are 2 methods, the easy or the hard way. :)

METHOD 1 (easy)
FIND:
Code:

  $loc=preg_replace("/\?s=[a-z0-9]{32}(&)?/","?",$loc);
REPLACE WITH:
Code:

  $loc=preg_replace("/\?s=[a-z0-9]{32}(&)?/","?",$loc);
  $loc = preg_replace( '~archive/~' , 'forumdisplay.php?forumid=' , $loc );
  $loc = preg_replace( '~forumdisplay/f-~' , 'forumdisplay.php?forumid=' , $loc );
  $loc = preg_replace( '~showthread/t-~' , 'showthread.php?threadid=' , $loc );
  $loc = preg_replace( '~-p-[0-9]~' , '' , $loc );
  $loc = preg_replace( '~.html~' , '' , $loc );

METHOD 2 (cool way)
FIND:
Code:

    case 'spider':
      $userinfo[where] = "Search Engine Spider";
      break;

REPLACE WITH:
Code:

    case 'spider':
      $userinfo[where] = "Search Engine Spider";
      break;
    case 'archive':
      $userinfo[where] = "$bbtitle <b>Archive</b> <a href='archive/'>Main Index</a>";
      break;
    case 'archiveforumdisplay':
      if (!$forum[forumid][$userinfo[forumid]] or (!$forum[canview][$userinfo[forumid]] and $hideprivateforums)) {
        $userinfo[where] = "Viewing <b>Archive</b> Forum";
      } else {
        $userinfo[where] = "Viewing <b>Archive</b> Forum <a href='forumdisplay/f-$userinfo[forumid].html'>".$forum[forumid][$userinfo[forumid]]."</a>";
      }
      break;
    case 'archiveshowthread':
      if (!$thread[title][$userinfo[threadid]] or !$forum[canview][$thread[forumid][$userinfo[threadid]]] or (!$forum[canviewothers][$thread[forumid][$userinfo[threadid]]] and $thread[postuserid][$userinfo[threadid]] != $bbuserinfo[userid])) {
        $userinfo[where] = "Viewing <b>Archive</b> Thread";
      } else {
        $userinfo[where] = "Viewing <b>Archive</b> Thread <a href='showthread/t-$userinfo[threadid].html'>".$thread[title][$userinfo[threadid]]."</a>";
      }
      break;

FIND:
Code:

  $loc=preg_replace("/\?s=[a-z0-9]{32}(&)?/","?",$loc);
REPLACE WITH:
Code:

  $loc=preg_replace("/\?s=[a-z0-9]{32}(&)?/","?",$loc);
  $loc = preg_replace( '~archive/~' , 'archive.php' , $loc );
  $loc = preg_replace( '~forumdisplay/f-~' , 'archiveforumdisplay.php?forumid=' , $loc );
  $loc = preg_replace( '~showthread/t-~' , 'archiveshowthread.php?threadid=' , $loc );
  $loc = preg_replace( '~-p-[0-9]~' , '' , $loc );
  $loc = preg_replace( '~.html~' , '' , $loc );

FIND:
Code:

  case '/robots.txt':
    $userinfo[activity] = 'spider';
    break;

REPLACE WITH:
Code:

  case '/robots.txt':
    $userinfo[activity] = 'spider';
    break;
  case 'archive.php':
    $userinfo[activity] = 'archive';
    break;
  case 'archiveforumdisplay.php':
    $blowup = explode('=', $token1);
    $forumid = intval($blowup[1]);
    $forumids .= ",$forumid";
    $userinfo[activity] = 'archiveforumdisplay';
    $userinfo[forumid] = $forumid;
    break;
  case 'archiveshowthread.php':
    if (strstr($token1,'threadid')) {
      $blowup = explode('=', $token1);
      $threadid = intval($blowup[1]);
      $threadids .= ",$threadid";
      $userinfo[activity] = 'archiveshowthread';
      $userinfo[threadid] = $threadid;
    } else if (strstr($token2,'threadid')) {
      $blowup = explode('=', $token2);
      $threadid = intval($blowup[1]);
      $threadids .= ",$threadid";
      $userinfo[activity] = 'archiveshowthread';
      $userinfo[threadid] = $threadid;
    }
    break;


Erwin 01-15-2003 10:15 AM

Nice hack, TECK. Just saw this one. Great work, as always. :)

Dean C 01-15-2003 03:35 PM

Quote:

Originally posted by TECK
Open the file and check the line, to make sure. :)
No, it doesn't use any extra space or duplicates any threads, etc.

Wow this is such a cool hack - extra traffic at NO cost whatsoever :)

Sounds too good to be true :D

I'll be telling my friends about this TECK ;)

- miSt

TECK 01-15-2003 04:31 PM

This the evaluation made by fastforward, an expert related to search engine optimizations.
TECK wrote on Today 02:11 AM:
[high]Hello fastforward,
I released a similar hack to yours and I would like to have your opinion on a issue.
My script uses Apache's ForceType directive. So "archive" will be treated as index.php or archive.php type.
Now, will this affect the crawlers to browse the archive, if I point them to:
http://www.teckwizards.com/archive/
and that represents for them the link to forcetyped "archive" file?

Thanks for taking the time to read this message.[/high]

fastforward wrote on Today 03:16 PM:
[high]Hello TECK,

The ForceType directive will be completely invisible to a crawler in the same way as using mod_rewrite. There should be no problems whatsoever.
I personally would use the 'archive' version without the extension. There is no evidence that Google or any other search engine identifies a dynamic file and handles it differently, but that could change if the capabilities of using dynamic pages are abused. (this is just my paranoid preference and not based on any hard facts).

It looks very nice by the way :)
I think I'll use that on my site that doesn't have the the friendly urls.

Paul[/high]

TECK 01-15-2003 11:02 PM

If you want to have the main archive file with a PHP extension and not as sub-folder, make the following changes to functions.php file:

FIND:
Code:

$bburl . '/archive/
REPLACE WITH:
Code:

$bburl . '/archive.php
NOTE: The code appears 2 times, change it in both places.
Rename the "archive" to archive.php.

I personally don't recommend you to do this, instead use both ways...
Leave the script unchanged but upload also archive.txt and rename it to archive.php, the crawlers will hit both files.

TECK 01-15-2003 11:11 PM

The actual settings are optimal for any server.
But, if you want to change the number of threads/posts displayed on each page, do the code change listed below.

FILE: forumdisplay.txt and showthread.txt
FIND:
Code:

$perpage =
Replace the numeric value with the one that suits best for your forum.
The bigger it is the faster the crawers will index your pages.

Do not go over value 400, just to make sure you give a break to your server also. :)

wooolF[RM] 01-16-2003 09:45 AM

]Great Hack TECK. You r00lez ;] Keep up the good job!

[high]* wooolF[RM] clicks INSTALL :> w00t :D[/high]

glenvw 01-16-2003 01:23 PM

I got a little lost here at the end...

You guys are too smart and techie for me :-)

Are you saying you re-released it so it has html extensions now and if yes, is it better to have the standard html extensions?

Thanks!

glenvw 01-16-2003 01:53 PM

[QUOTE]Originally posted by TECK
[B]Version 1.2 released.

Html extension were added to all dynamic pages.
I also fixed a minor bug related to dynamic meta tags.

Here it is also the fix for online.php file (requested by xiphoid):

Re:
Here it is also the fix for online.php file (requested by xiphoid):

I looked through the thread and cannot find reference to this.

What does the edits to the online.php file do?
Trying to decide it it is necessary..

TECK 01-16-2003 04:06 PM

If you view your online.php page, you see there the location (forum/thread/etc.) your users browse.
If it's a archive location, it will show you an Unknown Location:, instead of the actual link to the forum, for example.
The fix will display any links as VB links. Try it yourself, open 2 windows:
1. in the first window, go to go your online listings
2. in the second window go to your archive and browse to a forum or thread
3. refresh the first window to see the location you browse...


All times are GMT. The time now is 11:06 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.01754 seconds
  • Memory Usage 1,756KB
  • 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
  • (11)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
  • (2)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