Thank you. Ok I have managed to setup the MSQL+Apache server with MAMP and I have confirmed that PHP works on my computer by running the following .php file as per "Example 1" instructions from the "Your first PHP-enabled page"
<html><head> <title>PHP Test</title></head><body><?php echo '<p>Hello World</p>'; ?></body></html>
I have then tried running a .php file with the script "FoxyMod" mentions aboveFirstly, line 9 of the script (...) comes up as invalid syntax so I have removed it and tried running it. I just get a readout of the "-- Header -- -- Menu -- -- Footer --". I thought that perhaps replacing the $content with the dir to a html page would display it (see below), but it does not seem to work. Is there a practical example demonstrating the effect? I essentially would like to call a change in div contents through a menu click by loading different html pages...
<?php// Select content based on queryif(isset($_GET['p'])) { switch($_GET['p']) { case 'about': $title = 'About Us'; $content = 'gallery/gallery.html'; break; }}?><html><head> <title><?php echo $title; ?></title></head><body>-- Header ---- Menu --<?php include $content; ?>-- Footer --</body></html>
My current simplified site code
<!DOCTYPE html><html xmlns="http://www.w3.org/1999/xhtml"><head></head><body><div id="wrapper"> <div id="logo"><a href="slideshow/slideshow.html" target="iframe_content"><img src="logo.png" alt="Photography by xxx"></a></div> <div id="navigation"> <ul> <li><a href="gallery/gallery.html" target="iframe_content">gallery</a></li> <li><a href="#">technical</a></li> <li><a href="#">info</a></li> </ul></div><!--/#navigation--> <div id="content"><iframe name="iframe_content" src="slideshow/slideshow.html" marginwidth=0px marginheight=0px frameborder=0 width=600px height=600px></iframe> <!-- width and height must match #content css--> </div> <footer id="footer">© xxx 2013. All rights reserved.</footer></div><!--/#wrapper--></body></html>