Commit ca960783 authored by Jim Fulton's avatar Jim Fulton

Fixed a bug in handling the cancel redirect.

The test for the cancel button was case sensitive.
I changed it so it would accept any case, as well as extra spaces.
parent ec00eb46
...@@ -84,8 +84,8 @@ ...@@ -84,8 +84,8 @@
############################################################################## ##############################################################################
__doc__="""Python Object Publisher -- Publish Python objects on web servers __doc__="""Python Object Publisher -- Publish Python objects on web servers
$Id: Publish.py,v 1.114 1998/12/11 20:53:46 jim Exp $""" $Id: Publish.py,v 1.115 1998/12/29 18:10:12 jim Exp $"""
__version__='$Revision: 1.114 $'[11:-2] __version__='$Revision: 1.115 $'[11:-2]
import sys, os, string, cgi, regex import sys, os, string, cgi, regex
from string import lower, atoi, rfind, split, strip, join, upper, find from string import lower, atoi, rfind, split, strip, join, upper, find
...@@ -311,7 +311,7 @@ class ModulePublisher: ...@@ -311,7 +311,7 @@ class ModulePublisher:
# First check for "cancel" redirect: # First check for "cancel" redirect:
cancel='' cancel=''
if request_get('SUBMIT','')=='cancel': if lower(strip(request_get('SUBMIT','')))=='cancel':
cancel=request_get('CANCEL_ACTION','') cancel=request_get('CANCEL_ACTION','')
if cancel: raise 'Redirect', cancel if cancel: raise 'Redirect', cancel
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment