Click here to get back home

Web interface to script?

 HomeNewsGroups | Search | About
 comp.lang.perl.misc    Post an article   get this group's latest topics as an RSS feed add this group's latest topics to your My MSN content add this group's latest topics to your My Yahoo content
Subject Author Date
Web interface to script? Mike Stroud 09-19-2007
Get Chitika Premium
Posted by Mike Stroud on September 19, 2007, 5:02 pm
Please log in for more thread options
>>
>> [snip]
>>
>> > if I print "$1\n",
>> > the file prints just fine. But, if I do something like print "$1 after
>> > \n", the whole output is messed up. If I print "before $1\n", nothing
>> > prints at all. If I print "before $1 after\n", only after prints.
>>
>> not really sure, but could be a rogue "\r" in $1,


> There
> is a rogue carriage return (0xd) in the string

> Is there something I can do to deal with this
> situation?


Repair the corrupted file:

perl -p -i -e 'tr/\r//d' bad_file


--
Tad McClellan SGML consulting
tadmc@augustmail.com Perl programming
Fort Worth, Texas

Similar ThreadsPosted
Web interface to script? September 19, 2007, 5:02 pm
.perldb interface to DDD July 27, 2004, 12:52 am
.perldb interface to DDD July 28, 2004, 2:16 pm
Interface between C and Perl September 5, 2004, 6:15 pm
Website Interface August 15, 2006, 1:25 pm
Regexp::Common OO interface October 2, 2004, 7:56 pm
Perl interface to Unix ps? December 23, 2004, 3:24 pm
Web Interface and index.pl separated?!? April 13, 2005, 2:00 am
question on cloverleaf interface January 17, 2006, 5:01 pm
Perl - Gnuplot Interface September 5, 2007, 3:52 pm

Our other projects:

Art Dolls, Fairies and Mermaids - Sunnyfaces.net

Roy's Linux, Programming and Search Engines messages

1-Script XML SitemapXML Sitemap