Page 1 of 1

Replace text url by small gif

Posted: Thu May 22, 2008 8:20 pm
by MW24
Hi!

Your guestbook is great, thank you. It works fine as well. I have a short question though.

I do not want to have visible text links. When a visitor has a homepage it is listed in the guestbook as text.

<a href="go.php?url='.$url.'" class="smaller" '.$target.'>'.$url.'</a>

I want to replace the text-url by a small homepage-gif-image.

<a href="go.php?url='.$url.'" class="smaller" '.$target.'><IMG SRC="..." BORDER="0"</a>

works...the gif is clickable. The only problem is that this image always shows up even when a visitor has NO homepage. Is there a way only to display the image when the url is filled in and not empty?

Posted: Fri May 23, 2008 9:22 am
by Klemen
Which version of GBook are you using? Make sure it's the latest one (1.6) and make sure you are editing line 972:

Code: Select all

echo $lang['t19'].' <a href="go.php?url='.$url.'" class="smaller" '.$target.'>'.$url.'</a><br />';
It should work then and only show the image if an URL is present.

Posted: Fri May 23, 2008 11:07 am
by MW24
Thanks, it works now. :) Just made a small mistake.

Thanks again. :)

Posted: Fri May 23, 2008 11:19 am
by MW24
One last question: Which line displays the actual comment? Not the name, date, website, from...but the message the visitor has typed?

I want to add something there and can't find it.

EDIT Found it, thanks. :)