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)

Goomzee 04-06-2008 01:46 PM

i add php page it;s not working plz help me what i am doing wrong

here is a Link
http://www.mknexusonline.com/content/mkgames/test.php

sexyeyes83 04-14-2008 03:02 PM

Quote:

Originally Posted by amcd (Post 1483852)
hook online_location_process:
Code:

switch ($filename)
{
    case 'countries.php':
        $userinfo['activity'] = 'countries';
        break;
// add more cases here if you have more than one custom page. no need for multiple plugins. one plugin can handle all.
}


hook online_location_unknown
Code:

switch ($userinfo['activity'])
{
    case 'countries':
        $userinfo['where'] = '<a href="countries.php?'.$vbulletin->session->vars[sessionurl].'">Viewing the countries page</a>';
        $userinfo['action'] = "Who's Online by Country";
        $handled = true;
        break;
// add more cases here if you have more than one custom page. no need for multiple plugins. one plugin can handle all.


Where abouts do I find the online_location_process

Thanks

sabrina

amcd 04-14-2008 04:19 PM

Read the vbulletin manual, especially the chapter about plugins/hooks.

Per1213 04-15-2008 08:47 PM

I'm terribly confused by this entire thing.

The guide really doesn't explain this well for a newbie.

I've made the .php file and uploaded it to the FTP file manager then I have saved the template.... That's all the guide tells me to do and of course nothing has happened. What am I missing?

Digital Jedi 04-16-2008 07:18 AM

Quote:

Originally Posted by Per1213 (Post 1491566)
I'm terribly confused by this entire thing.

The guide really doesn't explain this well for a newbie.

I've made the .php file and uploaded it to the FTP file manager then I have saved the template.... That's all the guide tells me to do and of course nothing has happened. What am I missing?

Strictly speaking, it's not really meant for folks who haven't done a lot of customization to their site. Most folks wouldn't have any use for this, unless they've done a fair share of HTML coding, since that's where you take it after your done.

You say you saved the template and uploaded the PHP file. What happened when you navigated to the page?

Wunderlust 04-16-2008 11:13 AM

Hi All,

I have tried and tried for the last few hours to integrate this with phplist. Could someone please explain in laymans terms how this can be done simply!. I can change the directory because it is out side however all I want to use is the headers and the footers from vbulletin. I find myself hitting a major brick wall! Somebody please help!

if there are any experts out there who can do for a small fee I will gladly pay for their time.

Thanks in advance

tim

Per1213 04-16-2008 08:25 PM

Quote:

Originally Posted by Digital Jedi (Post 1491912)
Strictly speaking, it's not really meant for folks who haven't done a lot of customization to their site. Most folks wouldn't have any use for this, unless they've done a fair share of HTML coding, since that's where you take it after your done.

You say you saved the template and uploaded the PHP file. What happened when you navigated to the page?

I navigated to the page and nothing was there.

I need this new page because I want a page where I can place article links to get rid of the clutter in my forum.

Thanks for help

--------------- Added [DATE]1208381875[/DATE] at [TIME]1208381875[/TIME] ---------------

hey, okay so basically i copied and pated test.php to my publictml directory. I am now at a loss as to what to do from there. I dont mod VB alot all i wish is to have a page with a few links and a few bits of text. What do i do, i know i edit the bits labled test but i dont know what to edit them too. Please help guys!

ringleader 04-17-2008 08:12 AM

Quote:

Originally Posted by Per1213 (Post 1492457)
hey, okay so basically i copied and pated test.php to my publictml directory. I am now at a loss as to what to do from there. I dont mod VB alot all i wish is to have a page with a few links and a few bits of text. What do i do, i know i edit the bits labled test but i dont know what to edit them too. Please help guys!

You need two things for a basic page:
1. a php file calling a template
2. a template with the content for the page

Since you already have the file, you now need to create a template.

Look in your test.php and find a line that looks like this:
eval('print_output("' . fetch_template('TEST') . '");');

The bit that says TEST is the name of the template that is called when a person navigates to www.yourforum.com/test.php This name can be anything you choose.

So create a template called TEST by going to Styles & Templates -> Your style -> Add Template. Call it TEST, and put the example code provided in the first post of this article.

Edit the basic html to show the article links you want to show.
www.yourdomain.com/test.php should now show whatever you put in the template called TEST.

The last part of the tutorial is just so that when people are looking at the test.php page they show up on online.php list as 'Viewing article links' (or whatever you choose to say) instead of 'Unknown Location'.

Hope that makes more sense to you.

silver surfer 04-19-2008 07:46 PM

hmm...all i get is this

Warning: Unexpected character in input: '\' (ASCII=92) state=1 in /home/ede/public_html/test.php on line 2

Parse error: syntax error, unexpected T_STRING in /home/ede/public_html/test.php on line 2

i did step by step everything like in the tut.

any1 any idea ?

RVSmarter 04-19-2008 09:59 PM

I'm trying to have this page outside of the forum root folder.

I replaced

Code:

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

Code:

chdir('./forum_root_folder/');
require('./global.php');


www.mathhelpforum.com/downloads.php

And the images (curiously one of the images is working) and links are not looking in the forum root folder as they should. How do I fix that?


All times are GMT. The time now is 06: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.07546 seconds
  • Memory Usage 1,753KB
  • 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
  • (4)bbcode_code_printable
  • (4)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (4)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