• 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.

The parser in TWikiAttrsDotPm in its "friendly" mode allows an unnamed value in the attribute list. However, this is limited to start with a lowercase character.

I cannot see anywhere in the documentation or in documentation of past tags that the unnamed attribute should start with a lowercase character.

As it would be nice to use this parser to look at the last field in the form definitions (as discussed by CC), I propose that we allow the unnamed attribute to start with uppercase characters also.

A simple fix:

*** /e/www/twiki-dakar-4.0.2/lib/TWiki/Attrs.pm~   Fri Mar 31 23:44:35 2006
--- /e/www/twiki-dakar-4.0.2/lib/TWiki/Attrs.pm   Wed Sep 27 14:47:56 2006
***************
*** 131,137 ****
                    unless defined( $this->{$DEFAULTKEY} );
              }
              # simple name with no value (boolean, or _DEFAULT)
!             elsif ( $string =~ s/^$sep*([a-z]\w*)\b//s ) {
                  my $key = $1;
                  $this->{$key} = 1;
              }
--- 131,137 ----
                    unless defined( $this->{$DEFAULTKEY} );
              }
              # simple name with no value (boolean, or _DEFAULT)
!             elsif ( $string =~ s/^$sep*([a-zA-Z]\w*)\b//s ) {
                  my $key = $1;
                  $this->{$key} = 1;
              }


Done. Since the core doesn't use friendly mode (only plugins use it) this should not be listed in the releasenotes.

CC

ItemTemplate
Summary Attr.pm does not recognize unnamed values starting with uppercase
ReportedBy TWiki:Main.ThomasWeigert
Codebase ~twiki4
SVN Range TWiki-4.1, Sat, 23 Sep 2006, build 11571
AppliesTo Engine
Component

Priority Urgent
CurrentState Closed
WaitingFor

Checkins 11612
TargetRelease n/a
Edit | Attach | Watch | Print version | History: r4 < r3 < r2 < r1 | Backlinks | Raw View | Raw edit | More topic actions
Topic revision: r4 - 2006-09-27 - CrawfordCurrie
 
This site is powered by the TWiki collaboration platform Powered by PerlCopyright © 2008-2019 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding TWiki? Send feedback