vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vB3 General Discussions (https://vborg.vbsupport.ru/forumdisplay.php?f=111)
-   -   Settings Table (https://vborg.vbsupport.ru/showthread.php?t=50922)

mADmAX` 03-28-2003 04:51 PM

Settings Table
 
Edit (let me rephrase):

I have a url ($forumsurl) in the settings table in mysql. I am trying to call this url in certain parts of the forums for links. How do I make it pass this globaly (not sure where to put it). It will call it in the header/footer but not anywhere else.

filburt1 03-28-2003 05:09 PM

Settings are already in the global scope.

mADmAX` 03-28-2003 05:17 PM

PHP Code:

by <a href="$forumsurl/member.php?s=$session[sessionhash]&action=getinfo&find=lastposter&forumid=$forum[forumid]"><b>$forum[lastposter]</b></a

Would you happen to know why it wont call it there?

Dean C 03-28-2003 05:39 PM

Use the variable $bburl - that's what its for :D

- miSt

mADmAX` 03-28-2003 05:45 PM

$bburl would give me the directory for that part of the forums not the main forums.

I have 2 forums running sharing the database (one forums, one a file database). I want the certain links (like the profile of that user that posted it) to pull from the main forums profile page.

filburt1 03-28-2003 06:13 PM

As I said:

Quote:

Today at 02:09 PM filburt1 said this in Post #2
Settings are already in the global scope.

mADmAX` 03-28-2003 06:20 PM

Quote:

Today at 08:13 PM filburt1 said this in Post #6
As I said:


No offense but I am well aware how to read and as I stated, I know its suppose to but its not pulling it for some reason. I am not totally stupid on hacks, etc for vb so its not even that.

This is the code in forumhome_lastpostby:

PHP Code:

by <a href="$forumsurl/member.php?s=$session[sessionhash]&action=getinfo&userid=$lastpostuserid"><b>$forum[lastposter]</b></a

This is whats in $forumsurl:

PHP Code:

http://www.xxx.com/beta 

This is the url it gives when called on index.php:

PHP Code:

http://www.xxx.com 


-----------------
Its as if it see's the "/" after $forumsurl and goes to the root of the address. Almost as if $forumsurl is not defined but its called everywhere else I have it but here.

mADmAX` 03-28-2003 06:23 PM

I just tested $bburl in place of $forumsurl and it still doesnt display path for $bburl, it also goes to root of address.

filburt1 03-28-2003 06:48 PM

Make sure you're adding the variable to the options template. vB is dumb and has data redundancy in a lot of places.

mADmAX` 03-28-2003 06:59 PM

I did a little playing because I felt as if it was not passing globaly...

PHP Code:


$forumsurl 
$DB_site->query("SELECT value FROM setting WHERE varname ='forumsurl'");
$forumsurl $DB_site->fetch_array($forumsurl);
$forumsurl $forumsurl[value]; 

Placing that in index.php made it work but then I found out it doesnt pass in other places also. Seems it will pass these variables in header and footer and certain other parts but will not in lastposteby, postbits, etc.

Where would be a good place to place this to make it global since its a little faulty the current way it is.


All times are GMT. The time now is 03:28 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.01096 seconds
  • Memory Usage 1,746KB
  • 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
  • (5)bbcode_php_printable
  • (2)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (1)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