Gossamer Forum
Home : Products : Links 2.0 : Customization :

topx help - recent links on homepage

Quote Reply
topx help - recent links on homepage
i got this working -
http://www.gossamer-threads.com/perl/gforum/gforum.cgi?post=170573;search_string=topx.cgi;#170573

but is it possible to have the url link going to the actual entry listing rather that the entries url? even perhaps to go to the category page? what would the code be?


print qq|<tr><td>$i.</td><td><a href="$_[$db_url]">$_[$db_title]</a></td></tr>|;
}
print "</table>";
Quote Reply
Re: [arthurdavid] topx help - recent links on homepage In reply to
anyone got any ideas on this one?
Quote Reply
Re: [arthurdavid] topx help - recent links on homepage In reply to
here is what mine looks like. Maybe this will give you some ideas

Code:
print qq|<tr><td align=right>$i.</td><td>
<A class=mLink HREF="http://www.yoursite.com/cgi-bin/links/jump.cgi?ID=$_[$db_key[/url]]"
target=new onmouseover="window.status='$_[$db_title]';
doToolTip(event,150, '8pt', '#000000', '#DDECFF', 'solid', '<B>Added: $_[$db_dateadded]</B>');return true;"
onmouseout="window.status=' ';hideTip();return true;"> $_[$db_title]</A>
$_[$db_city] $_[$db_category]
</td></tr>|;


[/code]


Gene
"The older I get, the more I admire competence, just simple competence in any field from adultery to zoology."
Quote Reply
Re: [esm] topx help - recent links on homepage In reply to
that still just links to the url of their website rather than linking to the actual page in links.

i don't want them to link and go off to another website - i want them to link to the page where their full entry in links is?

do you know what i mean?

i have in topx.cgi -

print "Content-type: text/html\n\n";
print "<table>";
foreach (@data) {
$i++;
chomp;
split /\|/;
print qq|<tr><td>$i.</td><td><a href="jump.cgi?ID=$_[$db_key]">$_[$db_title]</a></td></tr>|;
}
print "</table>";

}
Quote Reply
Re: [arthurdavid] topx help - recent links on homepage In reply to
The closest Links knows where the actual listing is located is the Category - just look down the list of the field definitions in links.def for possible options.

I've never played with it but you can change where the "jump" goes to by changing $build_detailed in the links.cfg file. There has been a lot of posts on the subject here in the msg board, just do a search for info.


Gene
"The older I get, the more I admire competence, just simple competence in any field from adultery to zoology."
Quote Reply
Re: [esm] topx help - recent links on homepage In reply to
using $db_category only gives errors though.
Quote Reply
Re: [arthurdavid] topx help - recent links on homepage In reply to
use $_[$db_category]

but that only takes you to the category that the listing is in, not necessarily the page that it is on within the category.


Gene
"The older I get, the more I admire competence, just simple competence in any field from adultery to zoology."
Quote Reply
Re: [esm] topx help - recent links on homepage In reply to
thanks a million! that does the trick.
Quote Reply
Re: [arthurdavid] topx help - recent links on homepage In reply to
BUT one thing i have just noticed is that if i try to specify one of my own definitions 'job' on the link or others like 'phone' it just come back with id numbers...

<a href="$_[$db_category]">$_[$db_job]</a>
Quote Reply
Re: [arthurdavid] topx help - recent links on homepage In reply to
check your links.def file. In the section # Field Number of some important fields make sure you have defined db_job=xx where xx is a unique number with the listed fields in that section.


Gene
"The older I get, the more I admire competence, just simple competence in any field from adultery to zoology."