How to have a php include in the template

Use GitHub to post bug reports and error descriptions for phpwcms. Describe your problem detailed!
Locked
mattoo
Posts: 11
Joined: Sat 9. Jul 2005, 19:05
Contact:

How to have a php include in the template

Post 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:
pepe
Posts: 3954
Joined: Mon 19. Jan 2004, 13:46

Post by pepe »

Is it allowed to take an iFrame?
mattoo
Posts: 11
Joined: Sat 9. Jul 2005, 19:05
Contact:

Post 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');
?>
mattoo
Posts: 11
Joined: Sat 9. Jul 2005, 19:05
Contact:

Post by mattoo »

When I put that in the left area of the html. nothing shows up whatsoever!
pepe
Posts: 3954
Joined: Mon 19. Jan 2004, 13:46

Post by pepe »

Try:

{PHP:FullPathToYourScript/minitable.php}
mattoo
Posts: 11
Joined: Sat 9. Jul 2005, 19:05
Contact:

Post 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!
User avatar
pico
Posts: 2595
Joined: Wed 28. Jul 2004, 18:04
Location: Frankfurt/M Germany
Contact:

Post by pico »

Hi

try this

set

Code: Select all

$phpwcms["allow_remote_URL"]  = 1;
in your conf.inc.php
Lieber Gott gib mir Geduld - ABER BEEIL DICH
Horst - find me at Musiker-Board
mattoo
Posts: 11
Joined: Sat 9. Jul 2005, 19:05
Contact:

Post 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.
User avatar
pico
Posts: 2595
Joined: Wed 28. Jul 2004, 18:04
Location: Frankfurt/M Germany
Contact:

Post by pico »

Hi

normaly you find the conf.inc.php in ../config/phpwcms/conf.inc.php
Lieber Gott gib mir Geduld - ABER BEEIL DICH
Horst - find me at Musiker-Board
mdgroot
Posts: 155
Joined: Wed 11. Feb 2004, 17:47
Location: Netherlands

Post by mdgroot »

This is working:

[PHP]include('tplleaguestats/minitable.php')[/PHP]
mattoo
Posts: 11
Joined: Sat 9. Jul 2005, 19:05
Contact:

Post by mattoo »

Fantastic! :D Thank you all for your time, very kind! :lol:
mattoo
Posts: 11
Joined: Sat 9. Jul 2005, 19:05
Contact:

Post 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!
Locked