Include Files

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
User avatar
Templeton Peck
Forum Commoner
Posts: 45
Joined: Sun May 11, 2003 7:51 pm

Include Files

Post by Templeton Peck »

Quick question about include files, If I have justhtml code I want to reuse can I just put the html code in an include file and then put an include statement in my php file to use it?

or do I have to set it up as a function in the include file that passes the html to the php file?
User avatar
phice
Moderator
Posts: 1416
Joined: Sat Apr 20, 2002 3:14 pm
Location: Dallas, TX
Contact:

Post by phice »

You can include any type of file you wish.

Just a simple...

Code: Select all

<?php
include("FILE_LOCATION.EXT");
?>
Image Image
Post Reply