[Home]WikiBugs/EndingWithDoubleDoubleQuotes

UseModWiki | WikiBugs | RecentChanges | Preferences

Ending with double double-quotes

Instead of:

    $UrlPattern = "((?:(?:$UrlProtocols):[^\\]\\s\"<>$FS]+)$QDelim)";
I would consider using:
    $UrlPattern = "((?:(?:$UrlProtocols):[^\\]\\s\"<>$FS]+))$QDelim";
The first pattern produces something that is understood by most (if not all) browsers, however, it is not valid HTML. (also, the comments in the code suggest that the double double-quotes are removed from the output). -- LaurensPit

Somewhat later ;-) To be clear: here is where it fails:

    [http://www.google.com"" Google (respect naar hen!)]

if you do the other UrlPattern? as suggested above it fixes that problem and the following lines are also not necessary anymore in SplitUrlPunct?:

  if ($url =~ s/\"\"$//) {
    return ($url, "");   # Delete double-quote delimiters here
  }

Same applies to InterLinkPattern. -- LaurensPit

I will need to look into this further. The change you suggest would alter the behavior of double-quotes--one would no longer be able to use double-quotes to keep trailing punctuation in a URL. For instance, http://www.yahoo.com/test."" currently becomes http://www.yahoo.com/test. (with the trailing period as part of the URL). With your change the URL passed to SplitUrlPunct? would not include the double-quotes, so the trailing period would be removed.

In the meantime, if it hurts, don't do that. :-) --CliffordAdams

I have decided to keep the current behavior in 1.0. --CliffordAdams


UseModWiki | WikiBugs | RecentChanges | Preferences
Edit text of this page | View other revisions | Search MetaWiki
Last edited July 7, 2007 3:35 am by MarkusLude (diff)
Search: