Gossamer Forum
Home : Products : Gossamer Links : Development, Plugins and Globals :

Add condition in my global

Quote Reply
Add condition in my global
Hi,
i need to put a condition in my global, like:
Select only the datarecords, which are "MagArt = "gumag".

How can i insert this condition?

Code:
sub {
my ($output,$sth,$link);
my $search_db = $DB->table('Links');
my $ausgabe = $IN->param('Ausgabe');
$search_db->select_options ('ORDER BY Add_Date ASC Limit 20');
$sth = $search_db->select ( { Ausgabe => $ausgabe });
while ($link = $sth->fetchrow_hashref) {
if (length $link->{Title} > 200) {
$link->{Title} = substr($link->{Title}, 0, 20) . '...';
}
$output .= Links::SiteHTML::display ('login_gutscheine_include', $link);
}
return $output;
}


Thanks in advance!

Coyu
Subject Author Views Date
Thread Add condition in my global Coyu 2036 Apr 15, 2005, 12:54 AM
Thread Re: [Coyu] Add condition in my global
webmaster33 1946 Apr 15, 2005, 1:08 AM
Thread Re: [webmaster33] Add condition in my global
Coyu 1950 Apr 15, 2005, 3:28 AM
Post Re: [Coyu] Add condition in my global
Andy 1936 Apr 15, 2005, 4:50 AM