From mboxrd@z Thu Jan 1 00:00:00 1970 From: Matt Price Subject: syntax for blocks that the exporter should not render? Date: Tue, 3 Sep 2013 11:32:33 -0400 Message-ID: Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:43157) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VGsap-0000cx-Lo for emacs-orgmode@gnu.org; Tue, 03 Sep 2013 11:32:37 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1VGsao-00045R-AP for emacs-orgmode@gnu.org; Tue, 03 Sep 2013 11:32:35 -0400 Received: from mail-ee0-x230.google.com ([2a00:1450:4013:c00::230]:65481) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VGsao-00045I-3l for emacs-orgmode@gnu.org; Tue, 03 Sep 2013 11:32:34 -0400 Received: by mail-ee0-f48.google.com with SMTP id l10so3077349eei.35 for ; Tue, 03 Sep 2013 08:32:33 -0700 (PDT) List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: Org Mode Hi, certain lines are not rendered by the org exporter, but are instead interpreted as instructions, e.g.: #+AUTHOR: Matt Price I'm using org2blog/wp, which is only partially converted to the new exporter. It works pretty well, but not perfectly. It has the neat feature that, when I insert a link to a local image, it will upload that image to wordpress and link to the uploaded file. TO keep track of the location of those images, it writes lines like this to the org file: #+/home/matt/Matt_headshots/Matt Price/IMG_9367_.jpg http://2013.hackinghistory.ca/wp-content/uploads/2013/08/wpid-IMG_9367_2.jpg Recently I've noticed that these lines are actually being rendered by the underlying html exporter before export. I can (sort of) fix this by adding a filter to the exporter (thanks again Nicolas!): --------- (add-to-list 'org-export-filter-paragraph-functions 'matt-org-export-filter-paragraph-function) (defun matt-org-export-filter-paragraph-function (paragraph backend info) "removes comments from export" (when (org-export-derived-backend-p backend 'html) (replace-regexp-in-string "^#\+.*$" "" paragraph) )) but it would be better if I could get the underlying exporter to just ignore these lines. I thought that the leading #+ was enough to get org to treat these lines as non-text -- but I guess I'm wrong! Anyone know a solution? Thanks! Matt