Discover Habbo's history
Treat yourself with a Secret Santa gift.... of a random Wiki page for you to start exploring Habbo's history!
Happy holidays!
Celebrate with us at Habbox on the hotel, on our Forum and right here!
Join Habbox!
One of us! One of us! Click here to see the roles you could take as part of the Habbox community!


Results 1 to 1 of 1
  1. #1
    Join Date
    May 2013
    Posts
    2
    Tokens
    116

    Default [REL] Small Maintenance Script

    Have it Hooked up to one file so there is less clutter in files.
    If you have a DJ Panel or Usersystem, You can Put it in here and manage your website directly from your panel from anywhere.
    Email: [email protected] if you have any sugestions.
    PHP Code:
    <head>
    <!--Your Config File-->
    <?PHP include("config.php"); ?>
    <!--Your Config File-->

    <?PHP
        $query 
    mysql_query("SELECT * FROM site_settings");  //  'site_settings' is a table in the database
        
    $array mysql_fetch_array($query);
        
    $maintenance $array['maint'];
    ?>
    </head>
    <body>
    <?PHP
    ////////////////////////////MAINTENANCE CONTENT////////////////////////////
    if($maintenance === 'yes') {
    ?>
    <Title> Maintenance *SiteName* </Title>
            <!-------------------ANY HTML CONTENT----------------->
            <!--------CAN PUT MAINTENANCE LAYOUT IN HERE-------->
            <br>
            This is the maintenance page and this website is currently ON maintenance.

    <?PHP
    }

    ////////////////////////////MAINSITE CONTENT////////////////////////////

    elseif($maintenance === 'no') {
    ?>
    <Title>*SiteName*</Title>
            <!-------------------ANY HTML CONTENT----------------->
            <br>
            This is the Homepage and is NOT on maintenance.

    <?php
    }
    ?>
    </body>
    Code:
    CREATE TABLE IF NOT EXISTS `site_settings` (
      `id` int(11) NOT NULL AUTO_INCREMENT,
      `maint` text NOT NULL,
      PRIMARY KEY (`id`)
    ) ENGINE=InnoDB  DEFAULT CHARSET=utf8 AUTO_INCREMENT=2 ;
    
    INSERT INTO `site_settings` (`id`, `maint`) VALUES
    (1, 'no');
    Last edited by Bowler153; 03-11-2013 at 08:53 PM.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •