1

Topic: punbb.org extern.php

just a quick question. what is the php include punbb.org uses to show 'recent posts' on the main page i dont think i can replicate the same effects on my site. i would like to add something like that to my main aswell. the reason is i tried reading over the instructions in extern.php and everything went well but when a topic is posted in it does not move it to the top of the list. am i doing something wrong?

-gezz

2

Re: punbb.org extern.php

This is what I use:

<%include(http://nupusi.com/forum/extern.php?action=active&show=10)%>

3

Re: punbb.org extern.php

is this going to bump the topics that have been recently posted on to the top of the list?

-gezz

4

Re: punbb.org extern.php

It does on my site, any time a post is made to a topic, it goes to the top.

5

Re: punbb.org extern.php

Okay iv been using this method for the longest time untill my hosting provider decided to change the php.ini settings on me so that i cant use urls so i tried absolute paths and it didnt work because it thinks "extern.php?action=active&show=10" is the file name. Iv searched this on the forums here and im still puzzled. I think I have the same problem as Ludo does/did.

Feel free to move this topic to Trouble Shooting.

-gezz

6 (edited by gezz 2005-08-21 10:40)

Re: punbb.org extern.php

Anyone have a solution? hcgtv? ludo? richard? someone?

-gezz

7

Re: punbb.org extern.php

gezz wrote:

Okay iv been using this method for the longest time untill my hosting provider decided to change the php.ini settings on me so that i cant use urls

Change provider wink

No, really, calling extern.php locally won't working because it needs the $_GET array which will not be available if not called via URL.

The German PunBB Site:
PunBB-forum.de

8

Re: punbb.org extern.php

Thanks Tobi.

But... didnt ludo find a way around this? its weird I can include a script up with no parameters just fine via absolute paths... its the parameters that is screwing me over or maybe its just my host sad

-gezz

9

Re: punbb.org extern.php

I don't know about Ludos solution.

You cannot include a local file with parameters.
Of course you can do something like this.

Rename all occurences of $_GET to $get or something in extern.php

2. Where you want to include extern.php, define an array like this:

$get = array('action'=>'active',
   'show'=>'10');

and after that include extern.php locally.
Might work.....

The German PunBB Site:
PunBB-forum.de

Re: punbb.org extern.php

what is the html code I need to use to include extern.php as part of my homepage?

Re: punbb.org extern.php

you have to use php includes not html but a part of the html you use for your homepage. just read the comments inside extern.php and it will explain it all.

example:

<html>
<head>
<title></title>
</head>

<body>
<?php include('http://domain.com/forums/extern.php?action=active'); ?>
</body>
</html>
~James
FluxBB - Less is more