Go Back   vb.org Archive > vBulletin Article Depository > Read An Article > vBulletin 3 Articles
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools
Create Custom Pages
Princeton's Avatar
Princeton
Join Date: Nov 2001
Posts: 6,693

Joe Velez began developing for the web in 1998. He is an avid vBulletin user and volunteers his services as a vbulletin.org administrator. He currently spends his time maintaining and developing allnurses.com.

Vineland, NJ
Show Printable Version Email this Page Subscription
Princeton Princeton is offline 02-21-2006, 10:00 PM

GO-TOTAL LLC had everyone in mind when GTCustom Pages was created.
Custom pages can now be created with little or no coding knowledge.

If you know how to create a phrase within ADMINCP / LANGUAGES then you can create custom pages with ease.

First Download and install product and...

Let's Create A Custom "About Us" Page:
  1. In your favorite editor, create the contents of the page. HTML is allowed.
  2. When you finish with the contents of the page, create 2 phrases (an optional subtitle is available).
    • "gtcustom_about_header" - title of custom page
    • "gtcustom_about" - contents of custom page
    • "gtcustom_about_subtitle" -optional subtitle for custom page; the subtitle (table cell) will only display if it's created
  3. That's it! Now, go visit the page via URL: $vboptions[bburl]/goto.php?section=about
NOTE:
- Replace bold text with your choice of name. Follow naming convention as described above or the pages will not display.
- All 'xxx_header' phrases should be added to GLOBAL phrase group. (Needs to be global to display in navbar, etc.)
- All other phrases are required to be in GTCustom Pages phrase group. (If it's not here, cutom page will not work.)
Tips:
  • URL looks good with mod-rewrite enabled.
    For example, $vboptions[bburl]/goto/section/about, $vboptions[bburl]/goto_section_about.html
  • Use short names to prevent mod-rewrite (SEO links) problems. (It really depends on your setup. For example, some SEO scripts will convert every '_' into '/'. Which will prevent custom page from being displayed.)
    • Examples:
      • about - (GOOD)
      • terms - (GOOD)
      • privacy - (GOOD)
      • about_us - (BAD)
      • terms_of_service - (BAD)
      • privacy_policy - (BAD)

Examples Included With Product:
  • About Us Custom Page - phrases: gtcustom_about_header, gtcustom_about
    URL: $vboptions[bburl]/goto.php?section=about
  • Terms Of Service Custom Page - phrases: gtcustom_terms_header, gtcustom_terms
    URL: $vboptions[bburl]/goto.php?section=terms
    Additional options available in Admincp/ vBulletin Options/ Site Name / URL / Contact Details to create Terms of Service
  • Privacy Policy Custom Page- phrases: gtcustom_privacy_header, gtcustom_privacy
    URL: $vboptions[bburl]/goto.php?section=privacy
Now Let's Create Who's Online Location For All Custom Pages:
  • Oops, this feature is only available to those who donate.
  • What do you get? A new Custom Pages Plugin. All you have to do is overwrite the original.
Reply With Quote
  #22  
Old 07-23-2006, 01:58 PM
Oddjob Oddjob is offline
 
Join Date: Jan 2006
Location: Long Island, NY
Posts: 234
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Does anyone know if this works for 3.6?
Reply With Quote
  #23  
Old 10-10-2006, 02:38 AM
PoetJA-1975's Avatar
PoetJA-1975 PoetJA-1975 is offline
 
Join Date: Sep 2006
Location: Meh...
Posts: 1,218
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Hi PRINCETON - Fabulous Fabulous vB hack. I am soooo loving this one - I do have a question/issue about the layout. I think in vBadvanced there's an option to either Use Module Shell Template or NO!

My choice would be to not have the page in a "box" - so to speak - I would like to have the custom page aligned in the middle of the page, rather than in the Module shell - Is there anyway to accomplish this?

I am building an Amazon store for my forum - the link url is: http://www.jpicforum.info/goto.php?section=shop

You'll notice how the alignment of the store is off a bit... The inline frame code is from Amazon directly (also the html for my gtcustom_shop phrase) and is as follows:
Code:
<table cellspacing="0" cellpadding="0" border="0" width="100%">
<iframe src="http://astore.amazon.com/jpicforumforw-20" width="100%" height="4000" frameborder="0" scrolling="no"></iframe>
I'm not really sure if I can tweek that html at all. But I have managed to tweek the CUSTOM_SHELL template as follows:

PHP Code:
$stylevar[htmldoctype]
<
html id="moooo" dir="$stylevar[textdirection]lang="$stylevar[languagecode]">
<
head>
$headinclude
<title>$pagetitle $vboptions[bbtitle]</title>
</
head>
<
body>
$header
<br />
  
$showrandomquote
  
  
<div align="center">
  
  <
script type="text/javascript"><!--
  
google_ad_client "pub-6622330007501456";
  
google_ad_width 468;
  
google_ad_height 15;
  
google_ad_format "468x15_0ads_al";
  
google_ad_channel ="";
  
google_color_border "E7E3D2";
  
google_color_bg "E7E3D2";
  
google_color_link "800000";
  
google_color_text "000000";
  
google_color_url "008000";
  
//--></script>
  
<script type="text/javascript"
    
src="http://pagead2.googlesyndication.com/pagead/show_ads.js">
  </
script>
  
  </
div>
  <
br />
<
table cellspacing="0" cellpadding="0" border="0" width="100%">
  <
tr>
    <
td width="100%" valign="top">$HTML</td>
  </
tr>
</
table>$footer
</body>
</
html
Can you please help me to fix this code to where the the custom-shell-like box is removed and the Amazon store can sit right in the middle of the http://www.jpicforum.info/goto.php?section=shop page ------> I will surely appreciate your help!

ALSO thanx for providing this nice piece of mod/hack work - Very nice indeed

Jacquii.
Reply With Quote
  #24  
Old 10-17-2006, 11:20 AM
Princeton's Avatar
Princeton Princeton is offline
 
Join Date: Nov 2001
Location: Vineland, NJ
Posts: 6,693
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

hi PoetJA-1975,

I'm guessing that you want to remove the "box" enclosing the Amazon script. If so ...
REPLACE:
HTML Code:
<table cellspacing="0" cellpadding="0" border="0" width="100%">
  <tr>
    <td width="100%" valign="top">$HTML</td>
  </tr>
</table>
WITH:
HTML Code:
$HTML
If not the above template, you may have to edit the other template ... keep in mind that any changes you do to it may reflect on other custom pages.

If that's not what you are referring to can you be more specific?

Sorry for the delayed response ...
Reply With Quote
  #25  
Old 10-17-2006, 06:05 PM
PoetJA-1975's Avatar
PoetJA-1975 PoetJA-1975 is offline
 
Join Date: Sep 2006
Location: Meh...
Posts: 1,218
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Hey PRINCETON - Exactly... I'm trying to remove the box enclosing the Amazon script...

I tried the CUSTOM_SHELL template edit you suggested above - And it didn't work.

What do you mean by "other" template? I've looked at all GTCUSTOM PAGES Templates and the code you suggested is only on the CUSTOM_SHELL...

Jacquii.
Reply With Quote
  #26  
Old 10-17-2006, 09:04 PM
Princeton's Avatar
Princeton Princeton is offline
 
Join Date: Nov 2001
Location: Vineland, NJ
Posts: 6,693
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

the template you need to edit is "gtcustom_mypage"

however, if you edit that template other custom pages will have the same look (eg. no 'wrapper')
Reply With Quote
  #27  
Old 10-18-2006, 09:21 AM
PoetJA-1975's Avatar
PoetJA-1975 PoetJA-1975 is offline
 
Join Date: Sep 2006
Location: Meh...
Posts: 1,218
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

hey PRINCETON - just threwup a gallon of tainted beer - so trust me - I totally used to "no wrapper" :P ------ OK OK OK - more than enough info etcetera...

custom_mypage template:

PHP Code:
<table class="tborder" cellspacing="$stylevar[cellspacing]cellpadding="$stylevar[cellpadding]border="0" width="100%">
<if 
condition="$vbphrase['header_title']">
<
tr>
    <
td class="tcat" width="100%">$vbphrase[header_title]</td>
</
tr>
</if>
<if 
condition="$vbphrase['sub_title']">
<
tr>
    <
td class="alt2">$vbphrase[sub_title]</td>
</
tr>
</if>
<
tr>
    <
td class="alt1" valign="top">$vbphrase[content]</td>
</
tr>
</
table
What do I edit?

Jacquii.

btw - thank you everso kindly for helping me out with this issue. Perhaps I'll sleep for 24hrs and get over the throwup spree LOL :lick:
Reply With Quote
  #28  
Old 10-18-2006, 11:15 AM
Princeton's Avatar
Princeton Princeton is offline
 
Join Date: Nov 2001
Location: Vineland, NJ
Posts: 6,693
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

remove everything except ... $vbphrase[content]
Reply With Quote
  #29  
Old 10-19-2006, 01:45 AM
PoetJA-1975's Avatar
PoetJA-1975 PoetJA-1975 is offline
 
Join Date: Sep 2006
Location: Meh...
Posts: 1,218
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

GREAT - thanx PRINCETON! Much appreciation

Jacquii.
Reply With Quote
  #30  
Old 11-08-2006, 04:38 AM
texasf1racer's Avatar
texasf1racer texasf1racer is offline
 
Join Date: Oct 2006
Posts: 53
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Great mod! One brief question..

If I wanted one of my custom pages to "act" as the home page (like a portal) when someone visits my site url as usual, how would I do this?

Many thx!
Reply With Quote
  #31  
Old 11-08-2006, 11:27 AM
Princeton's Avatar
Princeton Princeton is offline
 
Join Date: Nov 2001
Location: Vineland, NJ
Posts: 6,693
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by texasf1racer
Great mod! One brief question..

If I wanted one of my custom pages to "act" as the home page (like a portal) when someone visits my site url as usual, how would I do this?

Many thx!
rename your forum index page (option can be found in admincp) to forum.php ...

now, rename the custom page to index.php


NOTE: This hasn't been tested.
Reply With Quote
Reply


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


All times are GMT. The time now is 05: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.10649 seconds
  • Memory Usage 2,327KB
  • Queries Executed 25 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)ad_showthread_beforeqr
  • (1)bbcode_code
  • (2)bbcode_html
  • (2)bbcode_php
  • (1)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)modsystem_article
  • (1)navbar
  • (4)navbar_link
  • (120)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (3)pagenav_pagelink
  • (11)post_thanks_box
  • (11)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (11)post_thanks_postbit_info
  • (10)postbit
  • (11)postbit_onlinestatus
  • (11)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open
  • (1)tagbit_wrapper 

Phrase Groups Available:
  • global
  • inlinemod
  • postbit
  • posting
  • reputationlevel
  • showthread
Included Files:
  • ./showthread.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/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_post_thanks.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
  • showthread_start
  • showthread_getinfo
  • forumjump
  • showthread_post_start
  • showthread_query_postids
  • showthread_query
  • bbcode_fetch_tags
  • bbcode_create
  • showthread_postbit_create
  • postbit_factory
  • postbit_display_start
  • post_thanks_function_post_thanks_off_start
  • post_thanks_function_post_thanks_off_end
  • post_thanks_function_fetch_thanks_start
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • fetch_musername
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • pagenav_page
  • pagenav_complete
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete