Page 1 of 1

How to have a php include in the template

Posted: Mon 1. Aug 2005, 19:49
by mattoo
Hello,

I would like to include the following league table from http://www.southport-fc.com/tplleaguest ... itable.php into the left hand column on the homepage template underneath the nationwide conference logo at http://www.southport-fc.com

Help would be gratefully appreicated, many thanks :lol:

Posted: Mon 1. Aug 2005, 20:31
by pepe
Is it allowed to take an iFrame?

Posted: Mon 1. Aug 2005, 20:35
by mattoo
Sorry not sure what that is...so havent got a clue! The site the the script comes from just tell you to use the include

<?php
include('tplleaguestats/minitable.php');
?>

Posted: Mon 1. Aug 2005, 20:35
by mattoo
When I put that in the left area of the html. nothing shows up whatsoever!

Posted: Mon 1. Aug 2005, 20:42
by pepe
Try:

{PHP:FullPathToYourScript/minitable.php}

Posted: Mon 1. Aug 2005, 20:47
by mattoo
still nothing, it just appears blank. My left column in template looks like this..

<img src="http://www.southport-fc.com/conf.jpg" width="200" height="85" border="0">
{PHP:http://www.southport-fc.com/tplleaguest ... itable.php}


and only image shows!

Posted: Mon 1. Aug 2005, 21:49
by pico
Hi

try this

set

Code: Select all

$phpwcms["allow_remote_URL"]  = 1;
in your conf.inc.php

Posted: Mon 1. Aug 2005, 23:03
by mattoo
Hi thanks for your post....I think that might be the answer. However, I did install the wcms via Fantastico and cant seem to find that config file, do you know where it should be or will it have been deleted? Can you access it via the admin panel?

Many thanks, time is much appreciated, sincerely.

Posted: Tue 2. Aug 2005, 00:07
by pico
Hi

normaly you find the conf.inc.php in ../config/phpwcms/conf.inc.php

Posted: Tue 2. Aug 2005, 00:43
by mdgroot
This is working:

[PHP]include('tplleaguestats/minitable.php')[/PHP]

Posted: Tue 2. Aug 2005, 11:53
by mattoo
Fantastic! :D Thank you all for your time, very kind! :lol:

Posted: Sat 6. Aug 2005, 18:09
by mattoo
OK something new. I want to use the following php include

<?php
include_once "/home/southpor/public_html/poll/booth.php";
echo $php_poll->poll_process(4);
?>

Using the [PHP] [/PHP] tags, anyone got any idea how I do that! Many thanks for your time!