Go Back   vb.org Archive > vBulletin Modifications > Archive > vB.org Archives > General > Member Archives
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools
Details »»

Version: , by (Guest)
Developer Last Online: Jan 1970 Show Printable Version Email this Page

Version: Unknown Rating:
Released: 07-26-2000 Last Update: Never Installs: 0
 
No support by the author.

Quick wink to JimF... and trying to follow his standard =P

I would like to be able to great my visitors on the front page of my site as well, using the info already gathered in vbulletin.

Is there a way that I can call the Name, Last Visit, Number of registered users, and other such items from the VB front page and use it on my sites front page?

Can I update the last visited date if they visit the site front page OR the vb front page?

Any help would be great!

Show Your Support

  • This modification may not be copied, reproduced or published elsewhere without author's permission.

Comments
  #2  
Old 07-27-2000, 12:50 PM
Guest
 
Posts: n/a
Default

thease are one of the things i will be adding to my board if i deside to go to this board. I can just make a small snip of a script that does this, but it might be a while before i get it done.
Reply With Quote
  #3  
Old 07-28-2000, 12:58 PM
Guest
 
Posts: n/a
Default

Nevermind all your helpfull people... I figured it out!! Took some more digging and a little playing but I got it.

I would post the way to do it, but it seems that no one is interested. If you are, then go ahead and reply.
Reply With Quote
  #4  
Old 07-28-2000, 02:47 PM
Guest
 
Posts: n/a
Default

I have to admit to being interested.. if no one else is you can feel free to email it to me, Id love to know
Reply With Quote
  #5  
Old 07-28-2000, 02:53 PM
Guest
 
Posts: n/a
Default

I'd have a use to do this too... please feel free to post the steps if it isn't too much trouble.

Thanks,
-Chris
Reply With Quote
  #6  
Old 07-28-2000, 06:50 PM
Guest
 
Posts: n/a
Default

Well,
What you'd have to do is follow the style that VB does with their other PHP files...

Create a PHP file, and put in it:
Code:
<?PHP
  require( "global.php" );
?>
That creates a DB connection to your vB mySQL DB, and now you can do anything you want with it!

However, if this PHP file is outside of your VB directory you must make sure that you put the path to global.php in the require( ) function call or it will fail.
Example:
Your VB directory is here: /home/httpd/www/boards/vb
Your PHP file is located here: /home/httpd/www/boards
Code:
<?PHP
  require( "vb/global.php" );
?>
Ok, now that you have the PHP doc connecting, you can place any code within the <?PHP ?> brackets - just like you are developing in VB!
Reply With Quote
  #7  
Old 07-28-2000, 10:51 PM
Guest
 
Posts: n/a
Default

I almost have to laugh. I make a request and no one responds or states that they are interested in it either. When I say that I figured it out, I get 2 requests from others that are interested and then someone posts how to do it FOR me.

Where were you people when I needed you BEFORE I figured it out?!?!?!?

Anyway... thanks mrogish for posting that. Saves me some typing.

When I did the above the first time it worked until the global.php required the admin/config.php which is puked on. So to fix that I did the below:
Code:
chdir("/path/to/boards"); 
require("/path/to/boards/global.php");
The chdir tells the script to start thinking it's in that new directory. And for some reason I couldn't get mine to work until I put the full path to the global.php as well.

Hope that helps if you have the same problem as I do.

Next time, speak up if you want a similar feature... it encourages the hackers to respond more then if it's just a single person
Reply With Quote
  #8  
Old 07-29-2000, 08:59 PM
Guest
 
Posts: n/a
Default

Aaron,
Sorry about that -- the large number of posts that the hack forum gets tends to push things to the bottom of the page, hence loss of exposure, etc., especially when there is a lot of talk about big things like PM and such.

Glad to help though!
Reply With Quote
  #9  
Old 08-21-2000, 12:24 AM
Guest
 
Posts: n/a
Default

I am bringning this thread as it is what I am trying to do (display the members/threads/posts numbers on a non vb page)

now... I did what was explained above with no success.

Also... I believe this hack displays the information on a PHP file right? What about displaying the info on a non php file (shtml)

Thanks in advance if you can explain me the steps.
Reply With Quote
  #10  
Old 08-21-2000, 03:34 AM
Guest
 
Posts: n/a
Default

Yes you have to use a .php file to use php code, unless you know of some way to execute .php from a .shtml file

Anyway this is what I did to get it to work using a .php file. PHP can give you fits with the right path and such so you have to do a chdir. Without the $DOCUMENT_ROOT, the require will fail.

Code:
<?php
chdir($DOCUMENT_ROOT . "/forums");
require($DOCUMENT_ROOT . "/forums/global.php");
?>
Make sure you put this as the FIRST thing in your index.php, nothing before it, no spaces, etc. If you don't you will get warnings about header information already being sent. You won't see these warnings if you already have a cookie set on your forum but your guests will and you would never know it if you never log out.

Then just use the vb Variables, i.e. like this for example

Code:
<?php
if ($bbuserid != 0)
{  echo("welcome back, <b>$bbusername</b>"); }
else
{  echo("welcome <b>guest</b>!"); }
?>
[Edited by rangersfan on 08-21-2000 at 12:35 AM]
Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 11:03 AM.


Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2024, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.04254 seconds
  • Memory Usage 2,270KB
  • Queries Executed 23 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)ad_showthread_beforeqr
  • (5)bbcode_code
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)modsystem_post
  • (1)navbar
  • (6)navbar_link
  • (120)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (2)pagenav_pagelink
  • (10)post_thanks_box
  • (10)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (10)post_thanks_postbit_info
  • (9)postbit
  • (10)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open
  • (1)tagbit_wrapper 

Phrase Groups Available:
  • global
  • inlinemod
  • postbit
  • posting
  • reputationlevel
  • showthread
Included Files:
  • ./showthread.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/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_post_thanks.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
  • showthread_start
  • showthread_getinfo
  • forumjump
  • showthread_post_start
  • showthread_query_postids
  • showthread_query
  • bbcode_fetch_tags
  • bbcode_create
  • showthread_postbit_create
  • postbit_factory
  • postbit_display_start
  • post_thanks_function_post_thanks_off_start
  • post_thanks_function_post_thanks_off_end
  • post_thanks_function_fetch_thanks_start
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • fetch_musername
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • pagenav_page
  • pagenav_complete
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete