Forums

The forums ran from 2008-2020 and are now closed and viewable here as an archive.

Home Forums Back End PHP dynamic content

  • This topic is empty.
Viewing 1 post (of 1 total)
  • Author
    Posts
  • #39635
    terryboxer
    Member

    I’ve figured out my own way to load dynamic content with PHP and it works fairly well. I just want to know how I can stop the page from ‘flashing white’ each time the content is changed. Feel free to suggest any ways how I could do this better.

    Here’s a snippet:

    
    if(empty($_GET)){
    include ('subcontent/home.php');
    include ('content/home.php');
    }
    else if ($_GET == 'home'){
    include ('subcontent/home.php');
    include ('content/home.php');
    }
    else if ($_GET == 'webdev'){
    include ('subcontent/webdev.php');
    include ('content/webdev.php');
    }
    else if ($_GET == 'software'){
    include ('subcontent/software.php');
    include ('content/software.php');
    }
    else if ($_GET == 'websites'){
    include ('subcontent/websites.php');
    include ('content/websites.php');
    }
    else if (!empty($_GET) ){
    include ('error.php');
    header( 'refresh: 6; url=index.php');
    }
    ?>
Viewing 1 post (of 1 total)
  • The forum ‘Back End’ is closed to new topics and replies.