Gossamer Forum
Quote Reply
Global Question 2
Hi to all !!!!
I want include MyLinks script on home.html but with a different templates...
trought Template Globals
This Global it's correct ??? :
---------------------------------------------------
sub {
# Displays Mylinks on the home page.
my ($output,$sth,$link);
my $search_db = $DB->table('Links');
$search_db->select_options ('ORDER BY ADD_DATE DESC Limit 5');
$sth = $search_db->select ( { isNew => 'Yes'});
while ($link = $sth->fetchrow_hashref) {
$link->{Title} =~ s,^(.{20}).*$,$1...,;
$output .= Links::User::Favorites::display ('NewTemplate', $link);
}
return $output;
}
--------------------------------------------------
Someone can help me ???


Thanks in Advance
Bye From Italy
Quote Reply
Re: [fabio] Global Question 2 In reply to
Please reply to your original thread in future.

http://www.gossamer-threads.com/...;;page=unread#unread

Have you tried the global, if so what happened, any errors?

Last edited by:

RedRum: Mar 4, 2002, 2:43 AM
Quote Reply
Re: [RedRum] Global Question 2 In reply to
No, I don't Have tested it.


Thanks in Advance
Bye From Italy
Quote Reply
Re: [fabio] Global Question 2 In reply to
Well that would probably be a good starting point :)

You realise it is just selecting 5 new links....that isn't the same as mylinks.

Last edited by:

RedRum: Mar 4, 2002, 3:07 AM
Quote Reply
Re: [RedRum] Global Question 2 In reply to
Ok thanks,
I must replace this line:
$sth = $search_db->select ( { isNew => 'Yes'});
but I don't know the code to get !!!!
Help Me !!!!


Thanks in Advance
Bye From Italy
Quote Reply
Re: [fabio] Global Question 2 In reply to
It looks like you have 2 code samples mixed up.

If you are just selecting 5 new links from the database, could I ask why you are using Favorites.pm ?

You would just need to use Links::SiteHTML::display
Quote Reply
Re: [RedRum] Global Question 2 In reply to
I want Use Favorites.pm
tell me wich cod I must use
please


Thanks in Advance
Bye From Italy
Quote Reply
Re: [fabio] Global Question 2 In reply to
Nobody can Help Me


Thanks in Advance
Bye From Italy
Quote Reply
Re: [fabio] Global Question 2 In reply to
Thanks Again........


Thanks in Advance
Bye From Italy
Quote Reply
Re: [fabio] Global Question 2 In reply to
You need to be clearer about what you are trying to do before someone can help.