I have included the modified code for the zap2xml.pl script: #original appendAsterisk subroutine #sub appendAsterisk { # my ($title, $station, $s) = @_; # if (defined($options{A})) { # if (($options{A} =~ "new" && defined($schedule{$station}{$s}{new})) # || ($options{A} =~ "live" && defined($schedule{$station}{$s}{live}))) { # $title .= " *"; # } # } # return $title; #} #modified code below sub appendAsterisk { #have to make the change to description rather than the title since I want to modify the description instead my ($description, $station, $s) = @_; if (defined($options{A})) { if (($options{A} =~ "new" && defined($schedule{$station}{$s}{new})) || ($options{A} =~ "live" && defined($schedule{$station}{$s}{live}))) { if (defined($schedule{$station}{$s}{new})){ #here I needed to make it add new to the title since it's a new episode $description .= " new"; } elsif (defined($schedule{$station}{$s}{live})){ $description .= " live"; #here I added live } } } return $description; } #original title and description portion # if (defined($programs{$p}{title})) { # my $title = &enc($programs{$p}{title}); # $title = &appendAsterisk($title, $station, $s); # print $FH "\t\t" . $title . "\n"; # } # print $FH "\t\t" . &enc($programs{$p}{episode}) . "\n" if defined($programs{$p}{episode}); # print $FH "\t\t" . &enc($programs{$p}{description}) . "\n" if defined($programs{$p}{description}); #modified code below if (defined($programs{$p}{title})) { my $title = &enc($programs{$p}{title}); #originally here my $description = &enc($programs{$p}{description}); #have to change this to the description $description = &appendAsterisk($description, $station, $s); #have to modify this to have the description changed, not title print $FH "\t\t" . $title . "\n"; print $FH "\t\t" . &enc($programs{$p}{episode}) . "\n" if defined($programs{$p}{episode}); #had to modify this to have it print up the modified description print $FH "\t\t" . $description . "\n" if defined($programs{$p}{description}); #needed to bring this up into the if loop or else cannot mess w/ description }