html >> Php includes? An html file?

by Jefferis NoSpamme » Wed, 21 Dec 2005 21:38:59 GMT

Hi all,
I'm working on table that has to be updated quarterly by a client using
either Contribute or DW. The table rotates each week and I have them
included right now in a page using php.inc

The problem is the client can't be trusted to edit an inc, so I have used an
html template with the table for manual editing [ I haven't used the DW
template lock, just sent a DW page].

My question, is there a way to include the html page within a page in php
without duplicating the html/header/body tags??

Just for clarification, the php.html page right now is structured as
follows:
html
Header
Body

Location specific content
Table // variable content from a called php.inc


/Body
/Header
/html

Thanks
Jeff
~~~~~~~~~~~~
Jefferis Peterson, Pres.
Web Design and Marketing
http://www.PetersonSales.com




html >> Php includes? An html file?

by boy mackman » Thu, 22 Dec 2005 18:48:06 GMT


well you could just make the page you send to your client not include the tags
and that it only includes the table code?

Otherwise you could make it into a database - which is probably the better
solution as then there is little way that the code will change.

Hope this helps




html >> Php includes? An html file?

by Jefferis NoSpamme » Fri, 23 Dec 2005 11:26:38 GMT

Thanks, I didn't think the table would display without the tags, but it
appears that it does.
Jeff


On 12/22/05 5:48 AM, in article doe096$5ck$ XXXX@XXXXX.COM , "boy



~~~~~~~~~~~~
Jefferis Peterson, Pres.
Web Design and Marketing
http://www.PetersonSales.com




Similar Threads

1. DW8, upon uploading .php files with include tags, it includes everything from the included pages - Adobe Dreamweaver

2. DW8, upon uploading .php files with include tags, it includes everything from the included pages

Line wrote:

> i just want it to upload the images or css file within that page, is there a way to prevent the included pages information from going up as well?
> 
> -Line


I'm not really sure i'm following what you are say, despite reading your 
question 3 or 4 times.

The basic answer is:

Whatever is in your included file page will upload to the page which has 
the include tags within it.

An include file should only include the information that you want to 
appear in the page that is sucking in the include file, ie delete all 
other unecessary information from it such as <body< <html> meta tags etc.

The css should be included within the global css for the page in which 
the include file appears within, not in the include file itself.

3. DW8, upon uploading .php files with include tags, it includes everything from the included pages - Adobe Dreamweaver

4. DW8, upon uploading .php files with include tags, it includes everything from the included pages

i just want it to upload the images or css file within that page, is there a way to prevent the included pages information from going up as well?

-Line

5. including html files in other html files

6. Previewing .html files with .php includes

I am trying to add includes to pages for a site hosted on an Apache server that 
have the file extension .html but I don't want to change any file names to .php.

 All works fine live, but Dreamweaver does not preview the included file:
 <? include('includes/test.html'); ?>

 Is there any reason I should not include both an .asp type include and the 
.php version as a workaround? Like this:
     <? include('includes/test.html'); ?>
     <!--#include file="includes/test.html" -->

 Is this bad practice or good lateral thinking?

 Your advice appreciated.

 Rich

7. Including files with PHP's include() function - Adobe Dreamweaver

8. including html files in a .html page