vBadvanced Forums   Build a community to build your business!
Go Back   vBadvanced Forums > vBadvanced Products > vBadvanced CMPS > Add-On Modules & Modifications > Module & Modification Discussion & Requests

Reply
 
Thread Tools Display Modes
  #1  
Old 08-23-2006, 08:21 PM
utw-Mephisto utw-Mephisto is offline
Member
 
Join Date: Feb 2005
Posts: 69
Default [How to] Add custompages to your forum

The reason I am doing this thread is simply because I get quite a lot of PMs asking how I did such and such page on my website.

If this is the wrong thread, any mod, feel free to move that one. But please leave a redirect since I send some people this link already - thanks

Anyway, some people would like to add for example flashchat, irc chat or simple iframes including all those modules etc. etc.

Some demos :

FlashChat
Custom Stuff

etc. etc.

So lets get started.

First, you need to create a template. Lets use as exmaple an iframe where google.com runs in it ...

Create a new template with the prefix adv_portal_ and name it for example google.

Admincp > Styles & Templates > Style Manager > In drop down choose Add New Template



Put in the code

Code:
$stylevar[htmldoctype]
<html dir="$stylevar[textdirection]" lang="$stylevar[languagecode]">
<head>
$headinclude
<title>$vboptions[bbtitle]</title>
</head>
<body>

$header
$navbar
<!-- Custom Code Start Here -->
<center>
<iframe src="http://www.google.com" width="80%" height="400"></iframe></center>
<!-- / Custom Code Ends here -->
$footer
</body>
</html>
and call it adv_portal_google



Now add a new Page which is Template Based



Page Title : What you would like to have displayed in the browser title bar
Page Identifier : This is the variable that will be used in the URL to link to this page. For example, if this option is set to 'games', then the link to this page would look like this: /cmps_index.php?page=games
Template : adv_portal_google

Should look something like



You don't have to use the Module Shell Template Options, only if you would like to have a typicall box around the stuff you display including the button to expand / collapse it

Now the important stuff : modules

There is not really a guideline for it ... The most important modul you need :

Custom Page Content

If you don't use it - you will get a white page ..

But for this example, lets disable all modules in the middle, except the one just mentioned, and some modules on the left and right. You will proparbly have a different module set, but once again : Custom Page content MUST and WILL be there



Since you named the identifier google - you can browse now to that page using

http://<domain>/cmps_index.php?page=google


IF you renamed cmps_index.php to index.php - you need to change that of course...

Here is a demo :

http://www.ut2007world.com/index.php?page=google




If you only would like to use a custom page without any modules, you can use the vbulletin build - in option

If you would like to add custom pages (including header / footer of your forum) do the following:

Add a new template in the style of your choice. You can name it whatever you want, it has to have the prefix
Code:
custom_
though.

You are then able to call the custompage using

http://www.ut2007world.com/misc.php?do=page&template=test2

Change the red code with your domain and the blue code with your template name accordingly.

Lets make an example.

Admincp > Styles & Templates > Style Manager > In drop down choose Add New Template

Name the template for example custom_google

Use the following code :

Code:
$stylevar[htmldoctype]
<html dir="$stylevar[textdirection]" lang="$stylevar[languagecode]">
<head>
$headinclude
<title>$vboptions[bbtitle]</title>
</head>
<body>

$header
$navbar
<!-- Custom Code Start Here -->
<center>
<iframe src="http://www.google.com" width="80%" height="400"></iframe></center>
<!-- / Custom Code Ends here -->
$footer
</body>
</html>
As you can see, I just use an iframe for you to see any results.

Now use your web-browser and go to

http://<domain>/misc.php?do=page&template=google

And change the domain to your own.

See attached a screenshot how the above example would look like. Or check out one Example - Don't get confused about the Muts_Overview.php filename though - this was created before I learned about the build in stuff, but it looks the same.

Also attached a default html code for a template.
Attached Images
File Type: jpg untitled.JPG (47.1 KB, 599 views)
Attached Files
File Type: txt custom_sometemplate.txt (301 Bytes, 188 views)
Reply With Quote
  #2  
Old 08-23-2006, 08:24 PM
SilverVice SilverVice is offline
Junior Member
 
Join Date: Jun 2006
Posts: 2
Default Re: [How to] Add custompages to your forum

Wow thanks a lot! I will try it asap and I let you know how is going.

Thanks again
Reply With Quote
  #3  
Old 08-23-2006, 08:41 PM
utw-Mephisto utw-Mephisto is offline
Member
 
Join Date: Feb 2005
Posts: 69
Default Re: [How to] Add custompages to your forum

You are welcome - I thought it might be better this way instead of email back and forth

Unfortunately I don't know how to do it easier - the only thing I can offer you is doing it myself on your site .. I don't speak french - but I'll manage
Reply With Quote
  #4  
Old 08-23-2006, 08:48 PM
SilverVice SilverVice is offline
Junior Member
 
Join Date: Jun 2006
Posts: 2
Default Re: [How to] Add custompages to your forum

Ok it's working now That's a very nice tutorial and thanks for the offer! I'm sure I will be able to use it to do a lot of things.

Thx again
Reply With Quote
  #5  
Old 08-24-2006, 12:12 AM
geoff's Avatar
geoff geoff is offline
Cannabalistic Lemur
 
Join Date: Sep 2005
Location: Oklahoma
Posts: 161
Default Re: [How to] Add custompages to your forum

very nice bro...thx for your advice
Reply With Quote
  #6  
Old 08-24-2006, 03:10 AM
rutch rutch is offline
Junior Member
 
Join Date: Apr 2005
Posts: 3
Default Re: [How to] Add custompages to your forum

Great THX a lot
Reply With Quote
  #7  
Old 08-27-2006, 08:38 AM
elricstorm elricstorm is offline
Junior Member
 
Join Date: Aug 2006
Posts: 19
Default Re: [How to] Add custompages to your forum

When I try all the steps outlined and I'm using 3.6 and the latest vbadvanced and php 5.0.4, when I add all of this, I get a blank page. I have custom content module enabled too. I'm not sure what's going on. I tried it in two different styles, "default" and in the one I use personally. Both get a blank page with no errors and nothing showing.
Reply With Quote
  #8  
Old 09-05-2006, 09:37 PM
jasharen jasharen is offline
Member
 
Join Date: May 2006
Posts: 34
Default Re: [How to] Add custompages to your forum

I'm trying to add a PHP file instead of a template and its giving me an error Could not find phrase 'adv_portal_invalid_file_path'.

Any help?
Reply With Quote
  #9  
Old 09-09-2006, 03:47 AM
popac popac is offline
Junior Member
 
Join Date: Sep 2005
Posts: 12
Default Re: [How to] Add custompages to your forum

Thank you utw-Mephisto, template working.
I have one more question, how can make
Code:
http://<domain>/cmps_index.php?page=google
to be my start page?
Now start page is:
Code:
http://<domain>
without prefix ?page=goole for example
Solution for start (index) page with template ?

Tnx in advance !
Reply With Quote
  #10  
Old 09-10-2006, 10:34 PM
Black Tiger Black Tiger is offline
Senior Member
 
Join Date: Sep 2006
Posts: 116
Default Re: [How to] Add custompages to your forum

Great tutorial!

1 little question. When you don't want to use the iframe, how is it done? It won't work with the "a href" statement. F.e. I have a links page in htm and want it displayed this way. But when boxed in iframe I also get a scrollbar and I just want the whole page displayed.

Last edited by Black Tiger; 09-10-2006 at 10:35 PM. Reason: added the last line.
Reply With Quote
  #11  
Old 09-17-2006, 06:33 PM
zaney zaney is offline
Junior Member
 
Join Date: Apr 2006
Posts: 5
Default Re: [How to] Add custompages to your forum

Good tutorial. I've gotten it to work somewhat. It seems that it changes the width of my left column when I use this. It makes it fatter. www.shoresofglory.org .... http://www.shoresofglory.org/forum/index.php?page=about

* I am not using the center column at all.

Anyone know what I can do to fix this?

+ I've fixed this issue.

Last edited by zaney; 09-17-2006 at 10:07 PM.
Reply With Quote
  #12  
Old 10-09-2006, 11:06 AM
admolot admolot is offline
Junior Member
 
Join Date: Aug 2006
Posts: 2
Default Re: [How to] Add custompages to your forum

Quote:
Originally Posted by jasharen View Post
I'm trying to add a PHP file instead of a template and its giving me an error Could not find phrase 'adv_portal_invalid_file_path'.

Any help?
I have the same problem.

Please Help me!
Reply With Quote
  #13  
Old 10-14-2006, 01:05 PM
thunder_sti thunder_sti is offline
Junior Member
 
Join Date: Sep 2006
Posts: 9
Default Re: [How to] Add custompages to your forum

How about for 3.5.5, would this work??? if not where can i get this, add a custome page/s???????

Thanks..
Reply With Quote
  #14  
Old 10-27-2006, 03:52 AM
chompboard chompboard is offline
Junior Member
 
Join Date: Oct 2006
Posts: 29
Default Re: [How to] Add custompages to your forum

Excellent tutorial
Reply With Quote
  #15  
Old 10-27-2006, 05:43 AM
afkae afkae is offline
Member
 
Join Date: Jul 2005
Posts: 30
Default Re: [How to] Add custompages to your forum

Great tutorial but how do I make other content from the page display inside the iframe?
This is the page I am talking about. When I click on something on the page it opens a completely different page. I would like to make it so it will function all inside the iframe.
Reply With Quote
  #16  
Old 11-10-2006, 07:20 PM
volarium volarium is offline
Junior Member
 
Join Date: Mar 2005
Posts: 14
Default Re: [How to] Add custompages to your forum

Do you know how this works with cookies? I am using this for an affiliate program. My page is here:

http://vfrworld.com/index.php?page=bikebandit

In your code, I included my affiliate ID in the link:

Quote:
<iframe src="http://www.bikebandit.com/partsbandit/default.aspx?WT.mc_id=6902&WT.mc_r=2&AID=1174801&PID=1886919" width="100%" height="1200"></iframe></center>
Any thoughts on whether the affiliate ID will be properly transferred to the user's computer, such that I will be credited with any sales that occur on my site?
Reply With Quote
  #17  
Old 12-05-2006, 04:17 PM
dina dina is offline
Junior Member
 
Join Date: Jun 2004
Posts: 11
Default Re: [How to] Add custompages to your forum

Hi,

I've tried everything now to add a custom page. I followed the instructions in this topic, and the second type of custom page is not a problem, but I want a custom page WITH the left side columns and navbar.

The problem is that when I go to the Portal and click on the link to the new custom page I'll still see the same main portal page (the url only changes to portal.php?=google instead of portal.php?page=google as described in this topic).
But if I go to http://www.board.com/forum/misc.php?...&template=info
I can see the content of the template, but I cannot see the left side columns and it's not really what I'm looking for.

I'm sure it's just a silly mistake I'm making, but could someone please point me in the right direction?

I run 3.6.4 and the latest portal.
Reply With Quote
  #18  
Old 12-06-2006, 08:53 AM
dina dina is offline
Junior Member
 
Join Date: Jun 2004
Posts: 11
Default Re: [How to] Add custompages to your forum

I hope someone can help me out with this problem?
Reply With Quote
  #19  
Old 12-12-2006, 04:54 PM
Sergio Sergio is offline
Junior Member
 
Join Date: Feb 2004
Posts: 10
Default Re: [How to] Add custompages to your forum

Really nice, it works perfectly, but...

I have problems if I want to include some PHP code into the page I made and I have problems with code parsing if I use the template method, have a look here please : http://www.vbulletin.com/forum/showt...=206162&page=2

Is it possible to do the same with include PHP instead of inclulde Template in a custom page ?
Reply With Quote
  #20  
Old 12-16-2006, 07:06 PM
alfisti alfisti is offline
Junior Member
 
Join Date: Dec 2006
Posts: 11
Default Re: [How to] Add custompages to your forum

Quote:
Originally Posted by popac View Post
Thank you utw-Mephisto, template working.
I have one more question, how can make
Code:
http://<domain>/cmps_index.php?page=google
to be my start page?
Now start page is:
Code:
http://<domain>
without prefix ?page=goole for example
Solution for start (index) page with template ?

Tnx in advance !
I also want to do the same.
Anyone who can help?
Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Removing Forum from Latest Forum Topics oly51 "How Do I..." Questions 11 07-19-2006 01:07 AM
i want the forum breadcrumb to goto root forum not portal. help markymoo Troubleshooting & Problems 1 05-18-2006 10:23 PM
News Module, display threads from one forum first, then from another forum GamingVidz.com "How Do I..." Questions 3 01-26-2006 03:37 PM
no forum link, forum displaying incorrectly digeraticular Troubleshooting / "How do I..." Questions 5 01-02-2005 06:23 AM


All times are GMT -4. The time now is 04:08 AM.

Forums Powered by vBulletin, Copyright ©2000-2009, Jelsoft Enterprises Ltd. ?&AID=10293998&PID=1523465
Please note that vBadvanced is in no way affiliated with Jelsoft Enterprises Ltd, nor will Jelsoft be able to provide any support for our products.