vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 3 Articles (https://vborg.vbsupport.ru/forumdisplay.php?f=187)
-   -   How to create your own vBulletin-powered page! (uses vB templates) (https://vborg.vbsupport.ru/showthread.php?t=62164)

Gary King 03-05-2004 11:15 AM

Quote:

Originally Posted by alkatraz
^ amen.. too many hacks/threads/hackers have been spoiled over pointless public accusations. if there's a problem, report it to the staff and leave it at that

Gary W: thx for answering my question =)

No problemo :)

gmarik 03-05-2004 04:18 PM

Not very promissing, waiting for somehting more fundamental ...

SVTBlackLight01 03-05-2004 04:37 PM

Quote:

Originally Posted by SVTBlackLight01
What's the best way to use this on a non-vb page?

OK. To answer my own question, on line 32, I replaced

Code:

require_once('./global.php');
with this

Code:

chdir('/home/site/public_html/testvb/');
require('./global.php');

;)

surfhog 03-05-2004 04:53 PM

Sorry newbie here, can some kind sole please explain what this is suppose to do.

I have created the test.php and called it and yes looks nice:) What is the template part for and how would you best make use of this please.

Thanks

lol well hush my mouth, I see now (-0-0-) ;)

Yes nice concept and thanks

monstergamer 03-05-2004 07:04 PM

i have done some thing like this a while ago and i loe it as i use it for my affialites and rules page

Gary King 03-05-2004 07:35 PM

Quote:

Originally Posted by gmarik
Not very promissing, waiting for somehting more fundamental ...

This is as basic as it gets ;)

dpakman91 03-05-2004 08:04 PM

alright, hopefully someone can help me with this:

i have some large files i want to make available to certain usergroups, but not other. the files are way too large to upload as "attachments" with vb so i would have to upload them via ftp and then just post a link in a thread...of course this means the only way to prevent people from downloading it is to prevent them from seeing the thread at all, which is not my intention.

with this new way of making a vb page, is there any way to do what i am trying to do?

any help would be great.

Gary King 03-05-2004 10:42 PM

Quote:

Originally Posted by dpakman91
alright, hopefully someone can help me with this:

i have some large files i want to make available to certain usergroups, but not other. the files are way too large to upload as "attachments" with vb so i would have to upload them via ftp and then just post a link in a thread...of course this means the only way to prevent people from downloading it is to prevent them from seeing the thread at all, which is not my intention.

with this new way of making a vb page, is there any way to do what i am trying to do?

any help would be great.

Try something like:

PHP Code:

<?php

require_once('./global.php');

if (
$_REQUEST[filename])
{
    if (
$bbuserinfo[usergroupid] == 6)
    {
        
header("Location: $_REQUEST[filename]");
    }
}

?>

Be sure to change the path to the global.php and the usergroupid as well (currently it's 6 for admins only).

Also, save this code in a file such as download.php and then you can use the file by linking to it like http://www.example.com/forum/downloa...=something.php which will download www.examlpe.com/forum/files/something.php if the user is an administrator.

Ryan Ashbrook 03-05-2004 10:55 PM

Nice job although I think personally this would be a template mod rather than a hack, since no vBulletin files were modified.

Still good job though. ;)

The Watcher 03-05-2004 11:44 PM

This looks promising gary -> a few questions !!!

1) How can I use this outside my forums directory? Do i just use this?

PHP Code:

chdir('/home/site/public_html/forums/');
require(
'./global.php'); 

2) How can I limit access to this page to only users in the usergroups 7, 8 and 9 ?

3) I have a php links script which I would like integrated into my forums in terms of the way it looks and the way only certain usergroups can access it. Can i use your hack to do this? If so, how I would I make a php page appear in the content area instead of the TEST template ???

Thanks again :)


All times are GMT. The time now is 02:23 PM.

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.02116 seconds
  • Memory Usage 1,743KB
  • 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
  • (2)bbcode_code_printable
  • (2)bbcode_php_printable
  • (4)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (3)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