Gossamer Forum
Home : Products : Gossamer Links : Discussions :

Clickable Admin Links?

Quote Reply
Clickable Admin Links?
Hi,

I've been searching the SQL forums for ages and haven't been able to find the answer to my question.. What do I need to do to make the links displayed in the Admin (when modifying and deleting, and after a new link has been added) change into a clickable URL which opens in a new browser?

Currently I am copying the URL and pasting it into the browser to visit the links, but it would be much more efficient to just click the link and have it open in a new window. I was using Links 2.0 with a mod that did this, and would like to have the same system with my Links SQL - but I don't know which files I need to update to do this.
Quote Reply
Re: [Evoken] Clickable Admin Links? In reply to
Hi,

This isn't an easy mod to figure out yourself as it's nested quite deep. You can edit admin/Links/Link.pm and right below:

$self->{code}->{LinkOwner} = \&disp_username;

add:

Code:
$self->{code}->{URL} = sub {
my ($self, $col, $rec) = @_;
return qq~
<tr><td><font $self->{font}>URL</font></td>
<td><font $self->{font}><a href="$rec->{URL}" target="_blank">$rec->{URL}</a></font></td>
</tr>~
};


that should do the trick.

Cheers,

Alex
--
Gossamer Threads Inc.
Quote Reply
Re: [Alex] Clickable Admin Links? In reply to
Thankyou so much Alex, I'll give that a try! Cool
Quote Reply
Re: [Evoken] Clickable Admin Links? In reply to
It worked, thanks Alex!

Without wanting to be too much of a pain, can I ask how I might turn the "URL" tag to the left of the URL to a clickable link in the multiple modify form?

Regards,
Amanda