Ignore:
Timestamp:
04/15/09 15:43:46 (3 years ago)
Author:
CrawfordCurrie
Message:

Item1383: make plugin get its preferences from global preferences, instead of from the plugin topic

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/PreferencesPlugin/lib/Foswiki/Plugins/PreferencesPlugin.pm

    r1493 r3447  
    2626use strict; 
    2727 
    28 require Foswiki::Func;    # The plugins API 
    29 require Foswiki::Plugins; # For the API version 
    30  
    31 use vars qw( $VERSION $RELEASE @shelter ); 
    32  
    33 # This should always be $Rev$ so that Foswiki can determine the checked-in 
    34 # status of the plugin. It is used by the build automation tools, so 
    35 # you should leave it alone. 
    36 $VERSION = '$Rev$'; 
    37  
    38 # This is a free-form string you can use to "name" your own plugin version. 
    39 # It is *not* used by the build automation tools, but is reported as part 
    40 # of the version number in PLUGINDESCRIPTIONS. 
    41 $RELEASE = 'Foswiki-1.0'; 
     28use Foswiki::Func ();    # The plugins API 
     29use Foswiki::Plugins (); # For the API version 
     30 
     31use vars qw( @shelter ); 
     32 
     33our $VERSION = '$Rev$'; 
     34our $RELEASE = 'Foswiki-1.0'; 
     35our $SHORTDESCRIPTION = 'Allows editing of preferences using fields predefined in a form'; 
     36our $NO_PREFS_IN_TOPIC = 1; 
    4237 
    4338my $MARKER = "\007"; 
     
    8681    if ( $action eq 'edit' ) { 
    8782        Foswiki::Func::setTopicEditLock( $web, $topic, 1 ); 
    88          
     83 
    8984        # Replace setting values by form fields but not inside comments Item4816 
    9085        my $outtext = ''; 
     
    10297        } 
    10398        $_[0] = $outtext; 
    104            
     99 
    105100        $_[0] =~ s/%EDITPREFERENCES({.*?})?%/ 
    106101          _generateControlButtons($web, $topic)/ge; 
Note: See TracChangeset for help on using the changeset viewer.