Re: Counting the characters..

2003-07-07 Thread Oliver Schnarchendorf
> $description = "This is my description and it contains numerous __ > double underscore marks and __ these marks some special area in the > field" > > What I want to do is to count/extract the amount of times these > double underscore marks are used. Like in the above example it should > show

RE: Counting the characters..

2003-07-06 Thread Gupta, Sharad
Something like this may work: my $num = $description =~ tr/__/__/; See "perldoc perlop" for the "tr" operator. -Sharad -Original Message- From: Sara [mailto:[EMAIL PROTECTED] Sent: Sunday, July 06, 2003 11:50 AM To: [EMAIL PROTECTED] Subject: Counting the characters

Counting the characters..

2003-07-06 Thread Sara
There is a form field 'description' which is the input for CGI script. $description = "This is my description and it contains numerous __ double underscore marks and __ these marks some special area in the field" What I want to do is to count/extract the amount of times these double underscore