(5 replies, posted in Programming)

thank you both...
but now, how do i get the url out of the string to do a getimagesize on it?


(5 replies, posted in Programming)

if i have a string like this

"this is some text and this [img]http://url_to_image[/img] is an image".

how can i replace the part


<a href='http://url_to_image' target='_blank' border='0'><img src='http://url_to_image' width='100'></a>"
<a href='http://url_to_image' target='_blank' border='0'><img src='http://url_to_image' height='100'></a>"

if the width is bigger then the height, i want to put width='100',
if the height is bigger then the width, i want to put height='100',
i know i can do that with getimagesize

i tried something like this to determine whether i have to use width or height:

$image = 'http://localhost/users/images/top.jpg';
list($w, $h) = getimagesize($image);

echo "<a href=".$image." target='_blank'><img src=".$image." border='0' ";
if ($w > $h) {
 echo "width='100'>";
if ($h > $w) {
 echo "height='100'>";
echo "</a>";

i know this works...i just don't know how to replace that part of the string..(like what i described above.

thank you


(19 replies, posted in General discussion)

It has been confirmed that it was ETA

They can't have confirmed it, ETA says it weren't them, they do not claim the attack as being theirs. Some political parties in Spain want it to be the ETA because it would be in their benefit when the elections are being held in April.

They found a detonaters and Koranic messages in a van.

It are now over 1400 wounded people and this morning they said 199 people died and there are still quite some people fighting for their lives.

12 MILLION! people joined in the street protests, 12 MILLION! wow..


(17 replies, posted in PunBB 1.2 troubleshooting)

Paul wrote:

1. A business wants to use a forum for customer and potential customer questions. Because these are one off posts it is open to guests. You would have to vet posts in order to avoid the "your company is crap" type of contribution.

2. A school wants to set up a bbs on its intranet. They might well want posts approved by teachers and/or trusted student moderators before the posts get onto the board.

3. A local community wants to set up a board which is going to be used by children. It would be essential that everything that happens can be controlled and monitered by adults though in that case you would want rather tighter controls than post approval is going to give you on its own.

i still dislike it.. who's gonna post on forums where it takes a day before your post shows up?? not me.. smile As for #1,  would be better to use email instead of a forum roll

i'm trying to make a login thing on my index.php as well..that uses the userdata of punbb.. see http://www.dutcholsentwins.com
(no success yet though, didn't get it to work yet)


(17 replies, posted in PunBB 1.2 troubleshooting)

that way, i don't see the advantage of a forum anymore...those who post messages you don't want to be posted should simply be banned.
i myself would never participate on a forum where posts have to be validated first.. that's waaaaaaaay to annoying. But that's just my opinion wink


(23 replies, posted in PunBB 1.2 troubleshooting)

never mind, solved it


(23 replies, posted in PunBB 1.2 troubleshooting)

yes, thank you, it worked.


(23 replies, posted in PunBB 1.2 troubleshooting)

uhm, well.. i visit the forums by going to http://forum.dutcholsentwins.com
and i visit the site by going to http://www.dutcholsentwins.com
so they are both the same domain... dutcholsentwins.com


(23 replies, posted in PunBB 1.2 troubleshooting)

but why? sad
anything that could fix it?


(23 replies, posted in PunBB 1.2 troubleshooting)

this is the output when i do that:



(23 replies, posted in PunBB 1.2 troubleshooting)

this is the output, whether i'm logged in or logged out..in both cases i get this as the output:

    [username] => Guest
    [is_guest] => 1


(20 replies, posted in Feature requests)

I don't need a subscribe feature at all.
The subscribe feature should've been left out, at least not a standard feature of punbb, if someone needed it someone could have written a mod for it wink but oh well tongue


(23 replies, posted in PunBB 1.2 troubleshooting)

this is what i have in config.php

$cookie_domain = '';
$cookie_path = '/';

might it have something to do with the fact cookie_domain is empty?


(23 replies, posted in PunBB 1.2 troubleshooting)

sure thing smile

$pun_root = './forum/nl/';  // Path to the forum root directory (must be defined)
require $pun_root.'include/common.php';

if ($cookie['is_guest'])
    // The visitor is a guest. Do whatever.
    // The visitor is logged in.

    echo 'Hello '.pun_htmlspecialchars($cur_user['username']);


(23 replies, posted in PunBB 1.2 troubleshooting)

yes i have :s


(23 replies, posted in PunBB 1.2 troubleshooting)

i just soooooooo don't get it, that code won't work for me. even if i logged in to the forum
http://www.dutcholsentwins.com/uhm.php always sees me as a guest (so nothing appears on the sccreen). I have that problem on my own computer, on someone elses computer and on the computers of school...


(7 replies, posted in General discussion)

basalphenaar wrote:

A good book is the PHP bible. I have the Dutch version, and it's very good.

yeah same here smile


(8 replies, posted in PunBB 1.2 troubleshooting)

example of second method:

yeah, i had the same error, they told me to put an @ before the include,
so that would be

and it worked.


(2 replies, posted in PunBB 1.2 discussion)

yeah, my host also has fantastico integrated with cPanel... it's nice, would be cool of punBB makes it to fantastico smile

well, on my laptop i'm always a guest, it's a new laptop so there are/were no cookies on it yet when i tried. But after logging in i keep being a guest on that page...

it is so weird, after i gave manually removed the cookie from my hd, i'm logged off from the forum, but the page i put that code on still shows me as logged in and shows my username.... mmm.

for me it's the other way around, i'm always logged in, even after i logged out...
but it only shows "Hello", it does not show the username.


(12 replies, posted in Programming)

"aantal leden online" is dutch wink translated to english it would be "number of members online", so there you learned a bit of Dutch, whayeah you're happy now aren't you? roll lol

thank you both for your comments smile
well, a while back someone told me i should use fetch_array, but he might be wrong wink i'm pretty new to php and mysql.

i'm off to see how i can optimize it with your tips smile