• Do not register here on develop.twiki.org, login with your twiki.org account.
• Use View topic Item7848 for generic doc work for TWiki-6.1.1. Use View topic Item7851 for doc work on extensions that are not part of a release. More... Close
• Anything you create or change in standard webs (Main, TWiki, Sandbox etc) will be automatically reverted on every SVN update.
Does this site look broken?. Use the LitterTray web for test cases.

Email addresses are not rendered properly on the UserForm. It is most apparent when registering with more than two components in the domain, e.g., as Prime.Minister@parliamentNOSPAM.gc.ca.

(However, email addresses with more than 2 components to the domain are rendered correctly elsewhere, e.g., above.)

I found the cause. The text before mailto discovery looks like

 ... <tr valign='top'><td class='twikiFormTableRow twikiFirstCol' 
align='right'>Email</td><td>
Prime.Minister\@parliament.gc.ca</td></tr>

After line 1102 of Render.pm executes, it looks like:

 ... <tr valign='top'><td class='twikiFormTableRow twikiFirstCol' 
align='right'>Email</td><td>
<a href=\"mailto:Prime.Minister\@parliament.gc\">Prime.Minister\@parliament.gc</a>.ca</td></tr>

That code is:

$text =~ s/$STARTWW((mailto\:)?[a-zA-Z0-9-_.+]+@[a-zA-Z0-9-_.]+\.[a-zA-Z0-9-_]+)$ENDWW/$this->_mailLink( $1 )/gem;

with the earlier definitions of

my $STARTWW = qr/^|(?<=[\s\(])/m;
my $ENDWW = qr/$|(?=[\s,.;:!?)])/m;

The left angle bracket isn't in the ENDWW set of characters, so the regex engine has to backtrack to get to a character that is in that set, the period before .ca.

I don't know whether it would break something else, but the obvious and probably too simple solution is to include angle brackets in ENDWW.


Did you install the small fix which is on the TWiki:Codev.DownloadTWiki page?

Look for E-mail Address Rendering Fix

-- KJL


That's the ticket, thanks.

ItemTemplate
Summary Some email addresses not rendered properly
ReportedBy TWiki:Main.PeterScott
Codebase

SVN Range 4.0.2
AppliesTo Engine
Component

Priority Low
CurrentState No Action Required
WaitingFor

Checkins

TargetRelease n/a
Edit | Attach | Watch | Print version | History: r7 < r6 < r5 < r4 < r3 | Backlinks | Raw View | Raw edit | More topic actions
Topic revision: r7 - 2006-04-18 - WillNorris
 
This site is powered by the TWiki collaboration platform Powered by PerlCopyright © 2008-2018 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding TWiki? Send feedback