News:

CPG Release 1.6.29
During HTML5 upload, keep pseudo blank code 200 messages from triggering error condition
added Russian language
correct failure to use theme menu icons in album manager
minor vulnerabilities mitigation

Main Menu

PHP include in header table

Started by BrokenRules, July 22, 2004, 01:39:01 AM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

BrokenRules

I have a site using the caliSkinV6 template

I want to include a page in the header

Now -> http://cu2.noinfo.nl

But I want it like this -> http://cu2.noinfo.nl/index2.php?pagina=vragenlijst&soort=abc
(with the scrollbar in the top)

how can I include a .php file in the template in a table  ??? ???


erroneus

If you're using cpg1.3.x, and the solution you found worked for you. Let us know!
Reason I ask is I noticed they said it worked for them on 1.2.1, and someone using 1.3.0 was unable to get it working.

cbx040

Hi,

I did this change for v1.31 and it works great.

In functions.inc.php I replaced

$template = fread(fopen($template_file, 'r'), filesize($template_file));

with

//$template = fread(fopen($template_file, 'r'), filesize($template_file));
ob_start();                     // Start output buffering
include ($template_file);       // Parsed file goes to buffer
$template = ob_get_contents();  // Assign buffer to $template
ob_end_clean();                 // Clear buffer and turn off output buffering

and in my template.html I have added

<?php include 'file.html'; ?>

I have .html defined aswell as .php in my .htaccess file

AddType application/x-httpd-php .html

Hope this helps to make things clear.