|
Comprehensive Guide to Custom Page Creation
|
|
06-12-2009, 03:52 PM
Post: #1
|
|||
|
|||
|
Comprehensive Guide to Custom Page Creation
Section I. Introduction
Many people have wondered, how do you make your own custom MyBB Page? Well, it is actually quite simple, you just need to know the trick. I'll be borrowing zaher1988's tutorial in this one. Along with that, is dvb's tutorial and Yumi's PHP in Templates and Template Conditionals plugin. So please note that I used their tutorials to help make this one, it was absolutely not made alone. I just combined a few of my own knowledge and combined it with theirs'. Section II. Creation of PHP File First off, you need create a PHP file. Open up notepad and paste the following: PHP Code: <?phpIt's the Discuss Admin ยป [Your Page Name] Part. Also change the "example.php" to what your PHP file is called. Then, change every other example to your file name, but without the php extension. Section III. Creation of Template File Now, go to your Global Templates and create a template file titled whatever your PHP file is without the extension. So, in this case, it's "example" (remember, no uppercase if it was not used before!) Inside, paste the following: Code: <html>In between "<!-- Content: Start -->" and "<!-- Content: End -->" is what will show up to your users (aside from the header and footer) Section IV. Adding Your Content Like stated before, your content is displayed in between "<!-- Content: Start -->" and "<!-- Content: End -->". For a table, paste the code between the two "tags": Code: <table border="0" cellspacing="{$theme['borderwidth']}" cellpadding="{$theme['tablespace']}" class="tborder">Next, replace the "Example Page Content" with the content you need. Refer to the mini HTML guide at the end of this tutorial for help. Section V. User Permission First off, you need to download the PHP in Templates and Template Conditionals plugin, written by Yumi, a.k.a., ZiNgA BuRgA It will let you use PHP conditionals in your templates, which is what separates different user groups from each other, amongst other things. If only members can view: Code: <table border="0" cellspacing="{$theme['borderwidth']}" cellpadding="{$theme['tablespace']}" class="tborder">This is only applicable if your are using tables as your basic structure. Section VI. Who's Online After making the page, you need to make it more professional but adding it to the Who's Online Page (replacing the "Unknown Location Link"). First, open up inc/functions_online.php. Find: PHP Code: default:Add BEFORE: PHP Code: case "example": Next, still keeping the file open, find: PHP Code: }Add before that: PHP Code: case "example":For the "Viewing..." part, you can replace it with the message you want displayed. (remember, if you are using and words/conjunctions like can't, I'm, etc, you need to add a \ before the apostrophe) If you wish to follow my example, then change "example.php" to your PHP file name (complete, with extension) and change the Example Page to the navigation bit. Section VII. Mini HTML Guide Bolded Text: Code: <strong>Hyperlink (open in same window): Code: <a href="LINK">LINKNAME</a>Hyperlink (open in new window): Code: <a href="LINK" target="_blank>LINKNAME</a>Div (id, which is started with a #): Code: <div id="DIVNAME">Div (class, which is started with a .): Code: <div class="DIVNAME">Image: Code: <img src="IMGLINK" />Space (vertical): Code: <br */>Space/Indent (horizontal): Code: Section VIII. Credits Of course, I'd like to thank you guys for actually taking the time to read this long and dreadfully boring tutorial. Again, I would like to thank zaher1988, Yumi, and dvb for their wonderful tutorials. Thanks! This tutorial is copyrighted to Discuss Admin ![]() AF Marketplace | Zynge.net PM me w/ your email to get invited to Lockerz |
|||
|
06-12-2009, 06:12 PM
(This post was last modified: 06-12-2009 06:18 PM by Bilgecix.)
Post: #2
|
|||
|
|||
|
RE: Comprehensive Guide to Custom Page Creation
thanks..
i'll try to make it... |
|||
|
06-12-2009, 07:20 PM
(This post was last modified: 06-12-2009 07:56 PM by -Prowler-.)
Post: #3
|
|||
|
|||
|
RE: Comprehensive Guide to Custom Page Creation
Nice TUT!
Here's what it helped me wit (I opted to not include the who's online as it is just a rules page) http://thegamingcore.net/rules.php |
|||
|
06-18-2009, 11:18 AM
(This post was last modified: 06-18-2009 11:18 AM by Jed K.)
Post: #4
|
|||
|
|||
|
RE: Comprehensive Guide to Custom Page Creation
How can I make a custom page appear on the who's online list if it's in its own directory?
For example, my forum is at http://www.myforum.com/ But my custom page is http://www.myforum.com/custom/index.php Should I replace example with "custom" or with "index" or with something like "custom/index"? What happens if I have /custom/index.php AND /custom-2/index.php? How do I include both? I tried replacing example with "custom" and "custom-2" but it didn't work. Thanks. Hey, Mr. Feather! |
|||
|
06-18-2009, 12:19 PM
Post: #5
|
|||
|
|||
|
RE: Comprehensive Guide to Custom Page Creation
Though their are alot of tutorial on that topic, yet your's is unique and very good for all types of members
Good Work Infra...! <font size too large, removed. use NORMAL size only, like below> FIND OUT ABOUT MYBBCODES.COM |
|||
|
06-18-2009, 04:08 PM
Post: #6
|
|||
|
|||
|
RE: Comprehensive Guide to Custom Page Creation
Thanks, please note that I have used other's tutorials as well, as mentioned in the credits.
![]() AF Marketplace | Zynge.net PM me w/ your email to get invited to Lockerz |
|||
|
06-18-2009, 07:20 PM
Post: #7
|
|||
|
|||
RE: Comprehensive Guide to Custom Page Creation
(06-18-2009 11:18 AM)Jed K Wrote: How can I make a custom page appear on the who's online list if it's in its own directory? O_o Just put it on your ROOT mybb directory. |
|||
|
06-18-2009, 08:16 PM
Post: #8
|
|||
|
|||
|
RE: Comprehensive Guide to Custom Page Creation
He wants a sub directory though. he wants a site and a forum which some plugins and addons would conflict with.
Projects- Need PHP/ASP.Net Hosting? Try CXR Kirisute Gomen Windows isn't a virus. At least a virus does something. |
|||
|
06-19-2009, 04:08 AM
Post: #9
|
|||
|
|||
|
RE: Comprehensive Guide to Custom Page Creation
I don't want to just "put it in my ROOT directory"
As T0m said, I am building a site out of MyBB and thus separate directories are needed for organization. Everything else works fine, but this is one thing I haven't been able to figure out how to configure properly, so if anyone can help I would really appreciate it. OP perhaps? Hey, Mr. Feather! |
|||
|
06-20-2009, 03:59 PM
Post: #10
|
|||
|
|||
|
RE: Comprehensive Guide to Custom Page Creation
Anyone?
Hey, Mr. Feather! |
|||
|
« Next Oldest | Next Newest »
|
Search
Member List
Calendar
Help

![[Image: signature.png]](http://www.zynge.net/signature.png)



(I opted to not include the who's online as it is just a rules page) ![[Image: Prowler.png]](http://i704.photobucket.com/albums/ww45/prowler-98/Prowler.png)

