Changeset 4380 for waeup


Ignore:
Timestamp:
27 Jun 2009, 15:57:58 (16 years ago)
Author:
uli
Message:

Use new HTML code extractor function in form mixin.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • waeup/branches/ulif-rewrite/src/waeup/viewlets.py

    r4181 r4380  
    66from waeup.interfaces import (IUniversity, IWAeUPObject, IWAeUPXMLExporter,
    77                        IWAeUPXMLImporter)
     8from waeup.utils.helpers import getInnerHTMLPart
    89
    910grok.context(zope.interface.Interface)
     
    218219
    219220    def render(self):
    220         result = self.form.render()
    221         try:
    222             # strip all except the form part...
    223             result = re.match('^.+\(<form[^\>]+>.*</form>).+$', result,
    224                               re.DOTALL).groups()[0]
    225         except:
    226             # except there is no such part...
    227             pass
    228         return result
     221        html_code = self.form.render()
     222        return getInnerHTMLPart(html_code)
Note: See TracChangeset for help on using the changeset viewer.