View Single Post
  #1 (permalink)  
Old 03-09-04, 03:04 PM
APuppyDog APuppyDog is offline
Newbie Coder
 
Join Date: Jul 2003
Posts: 69
Thanks: 0
Thanked 0 Times in 0 Posts
Question calling on include file in specific place

Hello

I found a php album script and implemented it on a clients site, http://www.fijifestival.com/scripts/gallery/index.php it does everything I want except one little glitch. I am calling on a header and footer file in the code, but when you click on a thumbnail, it bring up a larger picture. I don't want the header and footer to be used on the popup. I am pasting the code as I have it, is it possible to omit the header and footer from the viewPhoto section of the code?

Code:
<?php include('../../new/header.php'); ?>
<?php

	// Set Include Path - change only if you move this file outside the default directory.
	ini_set("include_path","./");

	// SPARE USERS FROM USELESS WARNINGS
	// see http://www.php.net/manual/en/functio...-reporting.php for more info on
	// error reporting, and what you can make it do
	error_reporting();

	// Get Config and Global Functions

	require_once("includes/config.php");			// Config
	require_once("includes/functions.php");			// Functions
	require_once("includes/templateInterface.php");	// Template Interface

	// We're NOT working with the admin interface - let other functions know this
	$CONFIG['adminInterface'] = false;

	if ($_GET['act'] == "home") {
		displayHeader("List Albums");
		listAlbums();
		displayFooter();
	}
	elseif ($_GET['act'] == "viewAlbum") {
		displayHeader("View Album");
		viewAlbum();
		displayFooter();
	}
	elseif ($_GET['act'] == "search") {
		displayHeader("Search");
		viewAlbum();
		displayFooter();
	}
	elseif ($_GET['act'] == "viewPhoto") {
		viewPhoto();
	}
	else {
		displayHeader("List Albums"); // mod for ps
		listAlbums();
		displayFooter();
//		header("Location: " . $_SERVER['PHP_SELF'] . "?act=home");
	}

?>
<?php include('../../new/footer.php'); ?>
Reply With Quote