1 Replies - 905 Views - Last Post: 13 February 2014 - 07:56 AM

#1 Wolverine89   User is offline

  • D.I.C Head

Reputation: 0
  • View blog
  • Posts: 120
  • Joined: 14-January 14

Page content update when clicked on menu item

Posted 13 February 2014 - 03:58 AM

Hi guys,

I am doing some research the find the best way to update my page content.
some prior information:

My project uses an index.php which contains includes to my menu, header, content and footer. There is a Left_Content.php and a Right_Content.php how can i update my content when i click on a menu about, for example About. I want to update my left or right content without copying my code 20 or 30 times.

Code below:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"><head>

<meta http-equiv="Content-Type" content="text/html; charset=windows-1252">
<title>Book Store</title>
<link rel="stylesheet" type="text/css" href="css/style.css">
<div id="main_container">
	<div class="parrot"><img src="img/arrow.jpg" alt="" title=""></div>
	<div class="main_content">
    	include_once ("inc/Header.php")
        <div class="top_center_box"></div>
        <div class="center_box">
			include ("inc/Menu.php");
       	 	include ("inc/Middlebox.php");
        	include ("inc/Left_Content.php");
        	include ("inc/Right_Content.php");
			include ("inc/Footer.php");

		</div> <!--end of center box-->
	</div> <!--end of main content-->
</div> <!--end of main container-->

Webpage, so when clicked on about categories change to about information

Thanks in advance!

Is This A Good Question/Topic? 0
  • +

Replies To: Page content update when clicked on menu item

#2 modi123_1   User is online

  • Suitor #2
  • member icon

Reputation: 14045
  • View blog
  • Posts: 56,214
  • Joined: 12-June 08

Re: Page content update when clicked on menu item

Posted 13 February 2014 - 07:56 AM

You can have the links go to an entirely new page.. based on some sort of session variable passed.. or use an ajax control to load data from a databases.. there are multiple options.
Was This Post Helpful? 0
  • +
  • -

Page 1 of 1