I have followed the example in ExceptionHander.py. My ExceptionHandler class is defined within the context init file (__init__.py) And as far as i can tell, none of the default methods are being overwritten with my definitions.
from WebKit.ExceptionHandler import ExceptionHandler as _ExceptionHandler
class ExceptionHandler(_ExceptionHandler):
hideValuesForFields = ['creditcard', 'credit card', 'cc', 'password', 'passwd']
# ^ keep all lower case to support case insensitivity
if 0: # for testing
hideValuesForFields.extend('application uri http_accept userid'.split())
hiddenString = '*** hidden ***'
def work(self): _ExceptionHandler.work(self)
def contextInitialize(app, ctxPath): app._exceptionHandlerClass = ExceptionHandler
def publicErrorPage(self):
html = ['''<html><head><title>Testing Exception Handler</title></head><body bgcolor="green">TESTING PUBLIC<p></p>''']
html.append('</body></html>')
return string.join(html, '')
def privateErrorPage(self):
html = ['''<html><head><title>Testing Exception Handler</title></head><body bgcolor="green">TESTING PRIVATE<p></p>''']
html.append('</body></html>')
return string.join(html, '')
As far as i understand it, this should display a page in the web browser with a _GREEN_ background with the text either "TESTING PUBLIC" or "TESTING PRIVATE". Any ideas as to what i am missing? or if anything has changed from 0.7 to 0.8.1
Andrew S. Garbutt Programmer I / Network Admin Center for Comparative Medicine University of California, Davis Phone: 530-754-5929 Fax: 530-752-7914 http://ccm.ucdavis.edu
------------------------------------------------------- This sf.net email is sponsored by:ThinkGeek Welcome to geek heaven. http://thinkgeek.com/sf _______________________________________________ Webware-discuss mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/webware-discuss