vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 4 Articles (https://vborg.vbsupport.ru/forumdisplay.php?f=242)
-   -   [HOW TO - vB4] Create your own vBulletin page (https://vborg.vbsupport.ru/showthread.php?t=228112)

cellarius 08-11-2010 06:22 AM

Then why don't you create a custom php page in the CMS in the first place? No sense in recreating the whole CMS infrastructure, when you just could use it. ;)

Tahooma 08-11-2010 06:53 AM

Quote:

Originally Posted by cellarius (Post 2082043)
Then why don't you create a custom php page in the CMS in the first place? No sense in recreating the whole CMS infrastructure, when you just could use it. ;)

My goal is to integrate a mod which uses the whole width of the screen into the "3 columns" design.
As i am very ned wo vBulletin, i thought the easiest way would be to force the .php file into the templates.

Dragonsys 08-11-2010 08:51 PM

Quote:

Originally Posted by Wilfred1 (Post 2069928)
I wonder if you can help me with this one Lynne

The problem I have is defining the WOS statement for:
Code:

Unknown Location
/index.php?pageid=news_reader

What I have which doesn't work (the others do) is:
Code:

    case '../index.php?pageid=news_reader':
       
$userinfo['activity'] = 'News Reader';
        break;

and
Code:

  case 'News Reader':
        $userinfo['where'] = '<a href="../index.php?pageid=news_reader">News Reader</a>';
        $userinfo['action'] = "Viewing Page";
        $handled = true;
        break;


I am trying to find a solution for this as well. What I have tried i using the online_location_preprocess hook.

my code looks like this:
Code:

if ($loc == './error.php?error=400')
{
    $filename = 'error_400.php';
}
if ($loc == './error.php?error=401')
{
    $filename = 'error_401.php';
}
if ($loc == './error.php?error=403')
{
    $filename = 'error_403.php';
}
if ($loc == './error.php?error=404')
{
    $filename = 'error_404.php';
}
if ($loc == './error.php?error=500')
{
    $filename = 'error_500.php';
}

and then in online_location_process i have:
Code:

if ($filename == 'error_400.php')
{
        $userinfo['activity'] = 'error400';
}
if ($filename == 'error_401.php')
{
        $userinfo['activity'] = 'error401';
}
if ($filename == 'error_403.php')
{
        $userinfo['activity'] = 'error403';
}
if ($filename == 'error_404.php')
{
        $userinfo['activity'] = 'error404';
}
if ($filename == 'error_500.php')
{
        $userinfo['activity'] = 'error500';
}

But I still get Unknown Location.

ArtakEVN 08-13-2010 02:12 AM

Quote:

Originally Posted by LoveStream (Post 1916679)
Thank your tutor.
I had met following error, when I using this template page, there is a cookie sent already.

Uh!
PHP Code:

Unable to add cookiesheader already sent.
File: /www/forum/phoenixjournals.php
Line
1

Forums test 

I create scripts as phoenixjournals.php, but it occur if I logout.

How could I solve it? or what deos it mean in this case?

I hope your teaching. Thanks.

Maybe you save your file in unicode.

choitz 08-15-2010 07:19 PM

Hi,
This has all worked brilliantly after flicking a bit between the original and Lynn's article (more of a case of me having to get my head round it).

Now, I don't know if it's a roblem with my custom style, but standard html doesn't seem to be having any effect on my pages, for example:
Code:

<UL><LI>[</LI></UL> <STRONG></STRONG> <I></I>
but;
Code:

<a href="..."></a>
works. I'd be grateful for any ideas why?

Cheers

Lynne 08-15-2010 08:00 PM

Use a div of class="restore" around the code to get back to normal html.

choitz 08-16-2010 04:53 PM

Quote:

Originally Posted by Lynne (Post 2084421)
Use a div of class="restore" around the code to get back to normal html.

Thanks for helping me out with a n00b problem Lynn, for the record if anyone else has that problem the double quotes (")after A HREF are left in, but if you use single (') or none at all then it works. Thanks again Lynn!

AfterWorldForum 08-19-2010 09:02 AM

Lynne,

Thanks for converting the article to a vB4 version. It's very helpful for those of us offering some custom-built pages.

If you do not mind, I do have a question about tables, though. I've used the approach a lot where I offer a custom page to pull some custom data from the database. Typically, this means I connect to the db, pull out data, and then build one huge HTML string with tables to represent the data.

I have looked, but not managed to find a definite article on how to achieve the same but consistent with the vB4 coding standards. I have tried looking at the CSS classes used in the vB4 pages, but I have to admit that is kind of over my head (I will admit I did not spend THAT much time on it, considering I still am trying to solve lots of issues left over after the migration).

As a simple example, I used to use alt1 and alt2. I can wrap one of those div class="restore"> around the table definition, but were I to totally rewrite my pages so they also match with the vB4 styles I use, how would I go at that, exactly? And where would I be able to find the restore class in the new stylevar setup, so I could actually alter the (for instance) alt1 and alt2 tags?

Sorry if you feel I am hijacking your thread. I just have not found a way to actually solicit for an article or guide, and custom pages is where I imagine lots of people will be using tables.

Thanks in advance, and I apologize for what might appear as an thread hijack.

Peter

Lynne 08-19-2010 02:46 PM

If you do a Search in Templates for ".restore", you'll find them all defined in vbulletin.css. I never change things in that template though, the best thing to do is put new CSS in addiitional.css

If you need help with something, you just post in the main (vB$, in this case) forums. Usually you don't ask for an article, you just ask for help. Then, either the person helping, or the person who got helped, may throw together an article to help others.

AfterWorldForum 08-19-2010 04:23 PM

Quote:

Originally Posted by Lynne (Post 2086363)
If you do a Search in Templates for ".restore", you'll find them all defined in vbulletin.css. I never change things in that template though, the best thing to do is put new CSS in addiitional.css

If you need help with something, you just post in the main (vB$, in this case) forums. Usually you don't ask for an article, you just ask for help. Then, either the person helping, or the person who got helped, may throw together an article to help others.

Thanks Lynne. I'll have a peek at the vbulletin.css. Should that not work out, I'll post a question :)


All times are GMT. The time now is 06:23 AM.

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.02136 seconds
  • Memory Usage 1,763KB
  • 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
  • (7)bbcode_code_printable
  • (1)bbcode_php_printable
  • (5)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