Gossamer Forum
Home : General : Perl Programming :

@cut never introduced at xml_import2.cgi line 429.

Quote Reply
@cut never introduced at xml_import2.cgi line 429.
Just got a weird error popping up Unsure

Quote:
@cut never introduced at xml_import2.cgi line 429.
$word never introduced at xml_import2.cgi line 429.
$count never introduced at xml_import2.cgi line 429.
$new never introduced at xml_import2.cgi line 429.
$string never introduced at xml_import2.cgi line 429.

... its with this code (at least it seems to be)... I am just confused as to what the error means :(

Code:
# capitalize all the words in the given string. very useful.
sub capitalize {

my $string = $_[0];

if (!$string) { return; }

my @cut = split / /,$string;

my $new;
my $count = 0;
foreach my $word (@cut) {
$new = $new . ucfirst $word . " ";
}

chop $new; #get rid of trailing blank

$new =~ s/\// - /gi;

return $new;


}

TIA

Andy (mod)
andy@ultranerds.co.uk
Want to give me something back for my help? Please see my Amazon Wish List
GLinks ULTRA Package | GLinks ULTRA Package PRO
Links SQL Plugins | Website Design and SEO | UltraNerds | ULTRAGLobals Plugin | Pre-Made Template Sets | FREE GLinks Plugins!
Quote Reply
Re: [Andy] @cut never introduced at xml_import2.cgi line 429. In reply to
Never mind. I was missing a ; at the end of a line Blush

Cheers

Andy (mod)
andy@ultranerds.co.uk
Want to give me something back for my help? Please see my Amazon Wish List
GLinks ULTRA Package | GLinks ULTRA Package PRO
Links SQL Plugins | Website Design and SEO | UltraNerds | ULTRAGLobals Plugin | Pre-Made Template Sets | FREE GLinks Plugins!