def update(self): super(PageTitle, self).update() context = self.context request = self.request self.titleSeparator = component.getUtility(ISEO).titleSeparator if not ISite.providedBy(context): self.notRoot = True site = getSite() tags = IHTMLTags(site, None) if tags is not None and tags.isAvailable() and tags.title: self.portal_title = tags.title else: self.portal_title = getMultiAdapter( (site, request), IBreadcrumb).name tags = IHTMLTags(context, None) if tags is not None and tags.isAvailable() and tags.title: if not tags.appendSiteTitle: self.notRoot = False self.title = tags.title else: self.title = getMultiAdapter( (context, request), IBreadcrumb).name
def update(self): super(PageMeta, self).update() context = self.context tags = IHTMLTags(context, None) if tags is not None and tags.isAvailable(): self.keywords = tags.keywords self.description = tags.description self.canonicalLink = tags.canonicalLink if not self.description: dc = IDCDescriptiveProperties(context, None) if dc is not None: self.description = dc.description if not self.description \ or not self.keywords \ or not self.canonicalLink: tags = IHTMLTags(getSite(), None) if tags is not None and tags.isAvailable(): if not self.description: self.description = tags.description if not self.keywords: self.keywords = tags.keywords if not self.canonicalLink: self.canonicalLink = tags.canonicalLink
def update(self): self.content = self.context tags = IHTMLTags(self.content, None) if tags is not None and tags.isAvailable(): self.context = tags super(HTMLTagsEditForm, self).update() else: self.context = None