*** lib/TWiki/UI/View.pm.orig Thu Dec 30 13:35:27 2004 --- lib/TWiki/UI/View.pm Thu Dec 30 13:38:52 2004 *************** *** 147,152 **** --- 147,154 ---- $text =~ s/>/>\;/go; $text =~ s/\t/ /go; $text = "$vtext$text"; + # next line is for Codev.ViewUseCssInKoala + $tmpl =~ s/[.]invisibleInNormal/.invisibleInRaw/gos; } } *************** *** 190,195 **** --- 192,215 ---- # Create pages $tmpl =~ s/]*>//goi; my $editAction = $topicExists ? 'Edit' : 'Create'; + + # START of Codev.ViewUseCssInKoala patch + if ( $editAction eq 'Create' && &TWiki::Store::_readTemplateFile("oopscreate", $skin ) ) { + my $url = &TWiki::getOopsUrl( $webName, $topic, "oopscreate" ); + my $warndisplay; + # if a template oopscreate exists, use it and set the vars in it: + # %PARAM1% to the intended topic name + # %PARAM2% to none if the topic is a wiki topic, + # (use as a CSS class in the template) + if( (&TWiki::isWikiName($topic)) || ($topic =~ /^[A-Z]{3,}$/ ) ) { + $warndisplay = "none"; + } else { + $warndisplay = "warn"; + } + TWiki::redirect( $query, "$url¶m1=$topic¶m2=$warndisplay"); + return; + } + # END of Codev.ViewUseCssInKoala patch # Special case for 'view' to handle %EDITTOPIC% and Edit vs. Create. # New %EDITURL% variable is implemented by handleCommonTags, suffixes