Skip Menu |

This queue is for tickets about the Text-Autoformat CPAN distribution.

Report information
The Basics
Id: 26439
Status: new
Priority: 0/
Queue: Text-Autoformat

People
Owner: Nobody in particular
Requestors: holger [...] loomsday.co.nz
Cc:
AdminCc:

Bug Information
Severity: (no value)
Broken in: (no value)
Fixed in: (no value)



Subject: Crippled HTML Tags
Date: Tue, 17 Apr 2007 19:23:57 +1200
To: bug-Text-Autoformat [...] rt.cpan.org
From: "Holger [...] Loomsday" <holger [...] loomsday.co.nz>
Hi Damien, When ever I pass text containing HTML tags in to autoformat (verion Text-Autoformat-1.13, Perl 5.8.8 on Linux), it eliminates the space in the href tag, i.e. <a href="..."> ... </a> becomes <ahref="..."> ... </a> More over, I wanted to tell Autoformat not to touch any paragraphs that contain HTML code, using the "ignore" switch, but the problem above remains. Am I doing anything wrong, or is this really a... side-effect? ;-) Many thanks, Holger PS: Below you will find an example to reproduce the issue: #!/usr/bin/perl use Text::Autoformat qw(autoformat break_wrap); $msg = <<"."; You have been invited to attend <a href="http://f2.rdblin01/en/event/show_event/event_id/2">Test test event</a> I <a href="http://f2.rdblin01/en/event/accept_invitation/event_id/2">accept</a> this invitation I <a href="http://f2.rdblin01/en/event/decline_invitation/event_id/2">decline</a> this invitation . print autoformat $msg, { justify => 'left', break => break_wrap, right => 58, all => 1, ignore => qr/<\/?[^<>]+>/, };
#!/usr/bin/perl use Text::Autoformat qw(autoformat break_wrap); $msg = <<"."; You have been invited to attend <a href="http://flock2.rdblin01/en/event/show_event/event_id/2">Test test event</a> I <a href="http://flock2.rdblin01/en/event/accept_invitation/event_id/2">accept</a> this invitation I <a href="http://flock2.rdblin01/en/event/decline_invitation/event_id/2">decline</a> this invitation . print autoformat $msg, { justify => 'left', break => break_wrap, right => 58, all => 1, ignore => qr/<\/?[^<>]+>/, };