> I have delimited the fields in the logfile by ","..and delimited the
> last field for each entry with a "*".
>
> How do I get it to move to the next entry after the *, and print that to
> screen?
>
> open(READFILE, $log_file) ||
>
> print "The log file could not be opened",$BR;
>
> while(<READFILE>)
>
> { @data = split( /\n/);

Why are you looking for the end of line if your next entry should be after a
* ? I'm not a guru perl but this one is seem to be the same error I would do
without thinking to it! Don't be shy, I am to a lower Perl knowledge but I
do lot of my code in Java but there's not only Java in the world... proud to
learn Perl's langage in those Java world...

And also... you may not keep your file open while printing to the screen...
what would append if to user try to one read the file and the other to write
to it... Don't know the code but I know it could be easilly done by
assigning the fille content to an Array, which will contain every line of
the file... Some guru migth help on this one!

By the way pardon me for my english... Ya Foeb With Beg or yet another
french on a english board with bad english grammar :P

>
> foreach $entry (@data)
>
> { ($d, $e, $f, $g, $h, $i, $j)= split(/,/, $entry);
>
> print "First Name : ", $d, $BR;
> print "Last Name : ", $e, $BR;
> print "City : ", $f, $BR;
> print "State : ", $g, $BR;
> print "Country : ", $h, $BR;
> print "Email : ", $i, $BR;
> print "Comments : ", $j, $BR;
> }
> }
> close(READFILE);
>



-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to