Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Need some help please
#1
Hi.

One question; I'm developing a main page and website for my forums, http://dotrb.net and I'm getting a little frustrated with my code. Everything works, it's just messy. Since I'm using PHP in it for some stuff, I want to know how to make PHP variables using HTML. Like MyBB does. For example;

Instead of doing:

Code:
<div id="header">
                    <div id="welcomeblock>
                    lol                
                    </div>
                <div align="left"><div class="logo">
                                </div>
                                                <div class="statistics">


</div>
            <div class="toplinks">
            
                <ul type="none">
                    <li><a href="index.php">Home</a></li>
                    <li><a href="design.php">Design</a></li>
                    <li><a href="##">Community</a></li>
                    <li><a href="##">Contact</a></li>
                    <li><a href="####">Profiles</a></li>
                    <li><a href="#####">Services</a></li>
                    <li><a href="#####">Software</a></li>
                    <li><a href="######">Staff</a></li>
                </ul>
            </div>

You can just do:

PHP Code:
{$header

Just to clear some things up. I just need it for the Side Bar and the Header; it's all so big and I have to copy paste on to every page lol.

Thanks.
At the top will be the same place you hang from.
Reply
#2
{$post}
{$user}
{$theme}
{$mybb->settings[‘bbname’]}
{$mybb->settings[‘bburl’]}
{$theme[‘imgdir’]}
{$theme[‘imglangdir’]}
{$mybb->user[‘email’]}
{$mybb->user[‘avatar’]}
{$mybb->user[‘uid’]}
{$mybb->user[‘postnum’]}
{$mybb->user[‘username’]}
{$mybb->user[‘logoutkey’]}
{$mybb->post_code}

* $clean_variables
* $config
* $cookies
* $cwd
* $debug_mode
* $ignore_clean_variables
* $input
* $magicquotes
* $request_method
* $settings
* $usergroup
* $use_shutdown
* $version
* $version_code

Here you go
Reply
#3
You didn't really give an explanation of how to use it though JOR.
[Image: donation_drive_sig.png]
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)