Back to index

plone3  3.1.7
Public Member Functions | Public Attributes
kss.core.parsers.HtmlParser Class Reference

List of all members.

Public Member Functions

def __init__
def __call__

Public Attributes

 soup

Detailed Description

Custom HTML parser

wraps the parser implementation

Definition at line 65 of file parsers.py.


Constructor & Destructor Documentation

def kss.core.parsers.HtmlParser.__init__ (   self,
  value 
)

Definition at line 73 of file parsers.py.

00073 
00074     def __init__(self, value):
00075         value = force_unicode(value)
00076         self.soup = self.BeautifulSoup(value)
00077         #
00078         # XXX ree: I think these are not needed any more. See
00079         # kukit patches r25865, r25866 that IMO fix this on IE.
00080         #
00081         #for tag in self.soup.fetch(recursive=False):
00082         #    tag['xmlns'] = "http://www.w3.org/1999/xhtml"

Here is the call graph for this function:

Here is the caller graph for this function:


Member Function Documentation

Definition at line 83 of file parsers.py.

00083 
00084     def __call__(self):
00085         value = unicode(self.soup)
00086         # Replace named HTML entitied in each case.
00087         # This is necessary for two reasons:
00088         # 1. Fixes an IE bug.
00089         # 2. Needed for the alternate transport mechanism to work.
00090         value = replace_html_named_entities(value)
00091 
00092         return value

Here is the caller graph for this function:


Member Data Documentation

Definition at line 75 of file parsers.py.


The documentation for this class was generated from the following file: