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 5 of 5
  1. #1
    JoeComins Guest

    Default Whats that code / tutorial for . . .

    Whats that code / tutorial for . . .

    Many PHP Pages in one?

    THanks


    bomb-head (forum moderator) - Moved to 'Coding', please post in the correct forum.
    Last edited by Bomb-Head; 04-11-2006 at 01:44 PM.

  2. #2
    Join Date
    Sep 2005
    Location
    East London
    Posts
    3,028
    Tokens
    0

    Latest Awards:

    Default

    PHP Code:
    <?
    include ("PAGE.php");
    include (
    "PAGE.php");
    include (
    "PAGE.php");
    include (
    "PAGE.php");
    include (
    "PAGE.php");
    include (
    "PAGE.php");
    include (
    "PAGE.php");
    include (
    "PAGE.php");
    include (
    "PAGE.php");
    ?>

  3. #3
    JoeComins Guest

    Default

    TUT - No

    I mean, you can have several pages in one. Like by clicking a link, it loads a certain part of the page, minimising files and space used.

    Either this, or whats the code for teh think where you click a link at it scrolls the page down for you?

    I cant remember, but I know how to use a PHP Include . . .

    For PHP Includes, I use:

    Code:
    <?php
    	$val = $_GET['id']; 
    	$val .= ".php"; 
    	$dirty = array("..");
    	$clean = array("");
    	$val = str_replace($dirty, $clean, $val); 
    	
    	if (isset($_GET['id'])) { 
    	if (file_exists($val)) { 
    	include "$val";
    	}
    	else {
    	include "404.php"; 
    	}
    	}
    	else {
    	include "home.php";
    	}
    	
    	// Include this script in your content area
    	// Run ?id=pagename (without .php) to view a page
    	?>

  4. #4
    Join Date
    Aug 2004
    Location
    UK
    Posts
    11,283
    Tokens
    2,031

    Latest Awards:

    Default

    i wrote it ages ago so its probably pretty crapy, but http://thybag.co.uk/?p=Tutorials&ind=23

  5. #5
    JoeComins Guest

    Default

    I knew I had seen it somewhere. I jsut wanted to read up on it.

    TY Carl

Members who have read this thread: 0

There are no members to list at the moment.

Posting Permissions

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