Click here to get back home

calling perl from html page

 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
calling perl from html page Moti 01-02-2008
Posted by Moti on January 2, 2008, 3:11 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
Calling a perl script from an html doc October 18, 2004, 12:44 pm
Using Perl to align text in an HTML page December 6, 2004, 11:45 am
Writing a "Hello world" HTML page from perl script ? June 11, 2006, 4:00 am
print cyriilic (UTF-8) characters with PERL on HTML page September 13, 2006, 4:59 am
A Web Development QUICK LINK PAGE (QLP) - HTML, Perl, PHP, JavaScript, AJAX, CGI, etc. May 1, 2007, 8:02 pm
XP prints out html not page ? August 28, 2004, 9:37 pm
Editing HTML Page July 18, 2008, 2:20 pm
Download a HTML page with images? April 25, 2005, 8:24 am
replace variable in html page May 18, 2005, 4:23 pm
need to generate HTML page which may have tables December 1, 2005, 11:38 pm

Our other projects:

Art Dolls, Fairies and Mermaids - Sunnyfaces.net

Roy's Linux, Programming and Search Engines messages

1-Script XML SitemapXML Sitemap