![]() |
How to call style Vb Stylesheet outside vb
okay in postnuke i could use iframes that would allow me to grab the style sheet for the theme i was using so i could use outside scripts to work with my site. now i am trying to bring something into vb right now with vbadvanced as a page but its not working because of how vbadvanced calls pages ?page=whatever.. now for the script it wont work so only way i am thinking is to i frame the script so it just lies within that module and then with a call to the style sheet the member is using i can match the Script to vb theme the current user is using.. see in post nuke i could call it
$theme = pnUserGetVar('theme'); echo "<link rel=\"StyleSheet\" href=\"themes/$theme/style/style.css\" type=\"text/css\">"; echo "<link rel=\"StyleSheet\" href=\"themes/$theme/style/styleNN.css\" type=\"text/css\">"; but in vb i dont know how i could achieve this can anyone help move this thread as well sorry posted in the wrong forum :( |
You can store the vbulletin stylesheet as a file, if that's any help :)
(look at your vBulletin Settings, yes that looong list) |
i figured it out :) it has to do with calling the global file then echoing the style
now i need to figure out how to echo the user name on a page outside of vb that wont work with a echo $userinfo[musername] :( |
Quote:
PHP Code:
|
Print out the array $vbulletin->userinfo and see which one stores the username and use that :).
*not sure it will work, my memory sucks* edit: Woops Tyler posted while I was posting. Tyler does this echo the formatted username? Cause I thought it was just username for the name but not sure... |
Quote:
|
Thanks, nice to know that! :D
|
thanks tyler and michelle for the help
Having a little bit more of an issue Code:
<? require_once('./global.php'); when i throw that in it completely kills the page after the call to the global |
Try:
PHP Code:
|
If its for a postnuke page, you might find including vbulletin's global file will mess up PHP's enviroment and stop it from working. I cant imagine it doing any real damage anymore since most things are stored inside classes.
You might have to chdir back to the directory your file is located in otherwise it wont be able to require the extra files that are required at the bottom of the code you pasted. |
All times are GMT. The time now is 10:57 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 | |
---|---|
|
|
![]() |
|
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|