From mboxrd@z Thu Jan 1 00:00:00 1970 From: Arun Isaac Subject: Bug: XML entities in the ox-rss exporter Date: Wed, 18 May 2016 00:50:28 +0530 Message-ID: <87r3d05w5f.fsf@gmail.com> Mime-Version: 1.0 Content-Type: text/plain Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:56139) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1b2qU0-0001Gk-6Y for emacs-orgmode@gnu.org; Tue, 17 May 2016 21:41:14 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1b2kY6-0006Zt-5C for emacs-orgmode@gnu.org; Tue, 17 May 2016 15:21:01 -0400 Received: from mail-pa0-x236.google.com ([2607:f8b0:400e:c03::236]:33673) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1b2kY5-0006Zn-VB for emacs-orgmode@gnu.org; Tue, 17 May 2016 15:20:58 -0400 Received: by mail-pa0-x236.google.com with SMTP id xk12so9432986pac.0 for ; Tue, 17 May 2016 12:20:57 -0700 (PDT) Received: from steel ([223.227.25.80]) by smtp.gmail.com with ESMTPSA id r86sm6589753pfb.21.2016.05.17.12.20.53 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 17 May 2016 12:20:55 -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" To: emacs-org The ox-rss exporter does not replace characters (such as < , > , etc.) by their corresponding XML entities (< , > , etc.) in the field of the generated XML. For example, the following org file, when exported, will produce invalid XML where the <title> field still contains the disallowed "<" character. ----- org file begins here ----- * Foo <- Bar Some text ----- org file ends here ----- I'm guessing the ox-rss backend similarly fails to handle XML entities in other fields as well. I can provide a patch for this. But, do I use an external library like xmlgen (https://github.com/philjackson/xmlgen), or do I write my own find and replace functions like those in ox-html? I think the xmlgen based approach provides better abstraction and avoids reinventing XML generation. But, it will introduce an additional dependency. Please provide thoughts and suggestions. Thank you, Arun Isaac.