def page_link_list(self): formats = ("creole", "html", "plugin") format = self.request.GET.get('format') if not format in formats: format = formats[0] page_list = flat_tree_list() context = { "page_list": page_list, "prefix": settings.PERMALINK_URL_PREFIX, "plugin_prefix": self.URLs.commandLink("permalink", "build"), "add_data_tag": mark_safe(settings.ADD_DATA_TAG), "formats": formats, "format": format, } content = self._get_rendered_template("page_link_list", context) # insert CSS data from the internal page into the rendered page: content = replace_add_data(self.context, content) return HttpResponse(content)
context["PAGE"].content = page_content # Get the template instance: consider the overwrite from page_style.switch() # or get the template from the current page object. template = get_template(request) # Get the content from the model instance template_content = template.content # Render the Template to build the complete html page: content = render_string_template(template_content, context) # insert JS/CSS data from any Plugin *after* the page rendered with the # django template engine: content = replace_add_data(context, content) # TODO: Remove in PyLucid >v0.8.5 middleware = 'PyLucid.middlewares.pagemessages.PageMessagesMiddleware' if middleware not in settings.MIDDLEWARE_CLASSES: msg = ( u"ERROR: %s not in settings.MIDDLEWARE_CLASSES!" " More info: %s" ) % (middleware, PAGE_MSG_INFO_LINK) content = content.replace(u"<!-- page_messages -->", msg) return HttpResponse(content)
slug = "png" ) if not sheet_url: self.page_msg.red("creole_cheat_sheet.png not found!") context["sheet_url"] = sheet_url #self.page_msg(markup_id, internal_page_name, context) content = self._get_rendered_template(internal_page_name, context) if markup_id == 2: # textile # Use tinyTextile markup content = apply_markup(content, self.context, markup_id) # insert CSS data from the internal page into the rendered page: content = replace_add_data(self.context, content) return HttpResponse(content) #___________________________________________________________________________ def tag_list(self): """ Render a help page with a list of all available django template tags and all available lucidTag's (List of all available plugins which provide lucidTag method). """ def _get_method_syntax(method): """ returns the argument string for the given method. e.g.: url="" debug="None" """