Wrox Programmer Forums

Need to download code?

View our list of code downloads.

Go Back   Wrox Programmer Forums > PHP/MySQL > BOOK: PHP and MySQL 24-Hour Trainer
Password Reminder
Register
Register | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read
BOOK: PHP and MySQL 24-Hour Trainer
This is the forum to discuss the Wrox book PHP and MySQL 24-Hour Trainer by Andrea Tarr ; ISBN: 978-1-1180-6688-1
Welcome to the p2p.wrox.com Forums.

You are currently viewing the BOOK: PHP and MySQL 24-Hour Trainer section of the Wrox Programmer to Programmer discussions. This is a community of tens of thousands of software programmers and website developers including Wrox book authors and readers. As a guest, you can read any forum posting. By joining today you can post your own programming questions, respond to other developersí questions, and eliminate the ads that are displayed to guests. Registration is fast, simple and absolutely free .
DRM-free e-books 300x50
Reply
 
Thread Tools Display Modes
  #1 (permalink)  
Old January 25th, 2014, 09:00 AM
Registered User
Points: 8, Level: 1
Points: 8, Level: 1 Points: 8, Level: 1 Points: 8, Level: 1
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Jan 2014
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Default Lesson 2 include function not working

In lesson 2 where you Include content/home.php within the index.php to pull the content in it doesn't populate that content. I thought it was something I was doing but when I pull up the final solution in the code examples it doesn't work their either. I'm using wamp locally on a windows 8 machine.
Any Clue why it's not working?

Index.php

Code:
<!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=UTF-8" />
<title>Smithside Auctions</title>
<link href="css/main.css" rel="stylesheet" type="text/css" />
</head>

<body>
<div id="container">

	<div id="header">
		<a href="index.html">
			<img src="images/banner.jpg"  alt="Smithside Auctions" />
		</a> 
	</div><!-- end header -->
	
	<div id="navigation">
		<h3 class="element-invisible">Menu</h3>
		<ul class="mainnav">
        	<li><a href="categories.html">Lot Categories</a></li>
        	<li><a href="about.html">About Us</a></li>
        	<li><a href="index.php">Home</a></li>
		</ul>
		<div class="clearfloat"></div>
	</div><!-- end navigation -->

	<div class="message">
	</div><!-- end message -->	
	
	<div class="sidebar">
	</div><!-- end sidebar -->
	
	<div class="content">
		<?php include 'content/home.php'; ?>
	</div><!-- end content -->
	
	<div class="clearfloat"></div>
	
	<div id="footer">
		<p>&copy; 2011 Smithside Auctions</p>
	</div><!-- end footer -->

</div><!-- end container -->
</body>
</html>
content/home.php

Code:
<h1>Next Auction September 22nd</h1>
        <p>Join us for our next auction of historic clothing
         to be held at the St. Paul's Auditorium in NYC on September 22nd at 1 o'clock.</p>
        
        <p>Lots can be viewed the prior day from 4pm until 7pm and again on Thursday morning from
         10am to noon.</p>
Reply With Quote
  #2 (permalink)  
Old January 25th, 2014, 09:05 AM
Registered User
Points: 8, Level: 1
Points: 8, Level: 1 Points: 8, Level: 1 Points: 8, Level: 1
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Jan 2014
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Default Figured it out

I was previewing in browser from Dreamweaver but didn't have the local server setup. Once I opened it up using http://localhost it worked fine.
Reply With Quote
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
Context Menu Not Working - Lesson 6 Ex 1 MinusZero BOOK: Stephens' C# Programming with Visual Studio 2010 24-Hour Trainer 2 October 23rd, 2012 11:26 AM
Lesson 35 - Scripts aren't Working on my server ZanderFly BOOK: JavaScript 24-Hour Trainer 4 March 15th, 2012 05:32 PM
include module function?? toshesh Access VBA 2 August 4th, 2006 02:00 PM
difference between include file & include virtual crmpicco Classic ASP Basics 2 January 23rd, 2006 10:50 AM
server include not working jgprentice Apache Tomcat 0 September 22nd, 2003 02:44 PM



All times are GMT -4. The time now is 10:23 PM.


Powered by vBulletin®
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
© 2013 John Wiley & Sons, Inc.