From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp12.migadu.com ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms5.migadu.com with LMTPS id 8CjwN/Fg1GLrGQEAbAwnHQ (envelope-from ) for ; Sun, 17 Jul 2022 21:20:17 +0200 Received: from aspmx1.migadu.com ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp12.migadu.com with LMTPS id mPHKN/Fg1GKaoAAAauVa8A (envelope-from ) for ; Sun, 17 Jul 2022 21:20:17 +0200 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id 9BE9C82E4 for ; Sun, 17 Jul 2022 21:20:17 +0200 (CEST) Received: from localhost ([::1]:55610 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1oD9oO-0003BZ-B7 for larch@yhetil.org; Sun, 17 Jul 2022 15:20:16 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:58166) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oD9np-00039W-St for emacs-orgmode@gnu.org; Sun, 17 Jul 2022 15:19:41 -0400 Received: from mail-lf1-x12f.google.com ([2a00:1450:4864:20::12f]:44653) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1oD9no-0007VW-8G for emacs-orgmode@gnu.org; Sun, 17 Jul 2022 15:19:41 -0400 Received: by mail-lf1-x12f.google.com with SMTP id a9so16170230lfk.11 for ; Sun, 17 Jul 2022 12:19:39 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=EfdEEv/5iF8Q/8J7sdOzXyYWZxsa+DOk50kCn//2lkY=; b=R207aOB/PTBJ5a/Kl85qq6QrBAPCgM1BZWpInEQ/ZpOjJZcOQlD9lcUS0vS3hF8IWE 4BxB0zO+jZyOI3AlpP9Kcr8ExvRsEAEYePnbwCPzeMFqZB/CAIyVpf1JXl7ux2+ts6z2 KutZlrhxbYfJTD3V0GOCP2PkQFva69L4XnHP+4T0GU/U3NsdA8YKiDyghoGKw4pUi8/f W7PT87UyaWtRC4B5uVZt1HMpY9PHzxZh97AgrKoIBXI7N4uh1dVFv/xLLY8XB8QW6xLh ZKxwA+uAhoGFZRwOc/vDF3wLN9YgDIdadr1jwHdAlXGodxaYDxyOd/zMVUGRjzizs6sL w+Rg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=EfdEEv/5iF8Q/8J7sdOzXyYWZxsa+DOk50kCn//2lkY=; b=HjpLiTryVdMWgSgV5WFYlXMGM34r/Afcr2xQ8dnZb9O9u7ROvigHk7xYfq7t3UhjoX alEpo2pVEmAchR7TNiMJr2xCBGWlbOGBMj/9fq4r0ysvDlyRBrebLZIoBkYAwsQcvvcZ jaBytrlhm5vT5obQEedaf0EDFiIz0OaJ5TA6fh2hgHjyJjCj5APIjTbegpcRqj7mNRzL 8Us1niqle1BsBqVOhmqHcRh6GORe3RIWI8XPH6xJ9t7YpYlgQjYBw7o0xYLpjkKOFObe 8ZoVn4OQEGsnUZOjsAee8nZTt9R6TKM475DV9ou+570OYcvDF1s6GkjubeG18bT4m2eZ 2XxA== X-Gm-Message-State: AJIora8tk424g56InR9Umm1ptn6lMkYqxC3hRLnKCeSOR56Xe+cO6q2/ EGecoSWYhEKZFl22/6z5htEn8D5xC6PsXVNBE4Y= X-Google-Smtp-Source: AGRyM1uWHxesWVny13JdZvjshOspQswJTP3Pwx5Spyzl9pLSS40QNMuPIGPqYFND0DP7D/UixJCVblfl6U6XQvKDy9w= X-Received: by 2002:a05:6512:3f9b:b0:47f:48b:ae0d with SMTP id x27-20020a0565123f9b00b0047f048bae0dmr12599907lfa.27.1658085577819; Sun, 17 Jul 2022 12:19:37 -0700 (PDT) MIME-Version: 1.0 References: In-Reply-To: From: kevinbanjo Date: Sun, 17 Jul 2022 12:19:26 -0700 Message-ID: Subject: Re: substitutions in html export? To: "Berry, Charles" Cc: Ihor Radchenko , emacs-orgmode Content-Type: multipart/alternative; boundary="000000000000df8b8405e405212f" Received-SPF: pass client-ip=2a00:1450:4864:20::12f; envelope-from=kevinbanjo@gmail.com; helo=mail-lf1-x12f.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, HTML_MESSAGE=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: emacs-orgmode@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+larch=yhetil.org@gnu.org Sender: "Emacs-orgmode" X-Migadu-Flow: FLOW_IN X-Migadu-To: larch@yhetil.org X-Migadu-Country: US ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1658085617; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type:in-reply-to:in-reply-to: references:references:list-id:list-help:list-unsubscribe: list-subscribe:list-post:dkim-signature; bh=EfdEEv/5iF8Q/8J7sdOzXyYWZxsa+DOk50kCn//2lkY=; b=EL9hMJDJZBcZMSFUpDpLXjbeuPZzBA0dXXVZFMQMMjMifFSKZg/+awC1FlLXJGcUY8Y3Pi oZ3MiVSPIt5Cgjqa1bL2Ba/XLon7NMb6CthU7nQIMzAnMNzdKQD+KIpWWXv4CSUlfENezQ HJbbml38fQGHcm0Oh+kQowjo4QbTCLp8ZhH6Ips6PnTsL4Qv6RjuKKdHc1ImBKbLSE4N96 hZcF7uZSIhl9LfwTy7H2UboLCo2WJRYz1Sh8WdRN7eQnGg2GzEXTvomQO3HF5V4ZKYCVsS +11jc2ff7HrpbMYeuOCFzFA1nkjnHCMaoHhUJc3gOIIBNp3UkvEmNK1YmstfcQ== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1658085617; a=rsa-sha256; cv=none; b=u0n1GqPxL6CH093lSElKwALPGyDwgFUWOijwwsB1c8vQFNte6Gf1y8mbUuAIZ7+UGP6J5M HYBCoOt6sn/aU85yl9BH1NqvrW07fvapLd2lgokbZf1lgM8CWHFWVsqEa5oVcXfziV3B5Z gKBez40a1iXRek5qf1L1hu2+LXuQfVmLRovkg7V/TzAOxBleR8jJD2Z3E5e7m+ZyJtjN3F rVJ1vLiwsVT3/QoPc28rcZSAFTbb1uv7+ix49EFdIInNIiQ7JOgpJveGXLY+Hi09dOuRhK GEhqfH1UnEl3CDYu3+uesdWSWDuPtocBZ5uAdpQkyMLH4uBx8u071mypi2ryFg== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=pass header.d=gmail.com header.s=20210112 header.b="R207aOB/"; dmarc=pass (policy=none) header.from=gmail.com; spf=pass (aspmx1.migadu.com: domain of "emacs-orgmode-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="emacs-orgmode-bounces+larch=yhetil.org@gnu.org" X-Migadu-Spam-Score: -2.73 Authentication-Results: aspmx1.migadu.com; dkim=pass header.d=gmail.com header.s=20210112 header.b="R207aOB/"; dmarc=pass (policy=none) header.from=gmail.com; spf=pass (aspmx1.migadu.com: domain of "emacs-orgmode-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="emacs-orgmode-bounces+larch=yhetil.org@gnu.org" X-Migadu-Queue-Id: 9BE9C82E4 X-Spam-Score: -2.73 X-Migadu-Scanner: scn0.migadu.com X-TUID: RTfkP4h/wjb1 --000000000000df8b8405e405212f Content-Type: text/plain; charset="UTF-8" On Sun, Jul 17, 2022 at 11:54 AM Berry, Charles wrote: > Kevin, > > > On Jul 17, 2022, at 10:18 AM, kevinbanjo wrote: > > > > > > > > On Sun, Jul 17, 2022 at 7:24 AM Ihor Radchenko > wrote: > > See inline calls in > https://orgmode.org/manual/Evaluating-Code-Blocks.html#Evaluating-Code-Blocks > > > > I did this and it didn't work (but the one outside the export block did): > > > > #+title:test > > > > #+name: numbers > > #+begin_src emacs-lisp :exports none > > 40 > > #+end_src > > > > #+begin_export html > > > > the result is call_numbers() > > > > #+end_export > > > The export block provides text that is to be used "as is" by the html > backend. So, "call_numbers()" is treated as html. > > You need to construct the export block programmatically. Maybe something > like > > #+begin_src emacs-lisp :results html :exports results :var num=numbers() > (format "the result is %d" num ) > #+end_src > > > HTH, > > Chuck > > > Thanks for that Chuck. It would seem a lot cleaner if there was a hook or something one could run that would just expand macros in export blocks before exporting them. -Kevin --000000000000df8b8405e405212f Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable


=
On Sun, Jul 17, 2022 at 11:54 AM Berr= y, Charles <ccberry@health.uc= sd.edu> wrote:
Kevin,

> On Jul 17, 2022, at 10:18 AM, kevinbanjo <kevinbanjo@gmail.com> wrote:
>
>
>
> On Sun, Jul 17, 2022 at 7:24 AM Ihor Radchenko <yantar92@gmail.com> wrote:
> See inline calls in https://orgmode.org/manual/Evaluating-Code-Blocks.html#Evaluating-Code-Bl= ocks
>
> I did this and it didn't work (but the one outside the export bloc= k did):
>
> #+title:test
>
> #+name: numbers
> #+begin_src emacs-lisp :exports none
> 40
> #+end_src
>
> #+begin_export html
>
> the result is call_numbers()
>
> #+end_export


The export block provides text that is to be used "as is" by the = html backend. So, "call_numbers()" is treated as html.

You need to construct the export block programmatically. Maybe something li= ke

#+begin_src emacs-lisp :results html :exports results :var num=3Dnumbers()<= br> =C2=A0 =C2=A0(format "the result is %d" num )
#+end_src


HTH,

Chuck



Thanks for that Chuck.=C2=A0=C2=A0 It = would seem a lot cleaner if there was a hook or something one could run tha= t would just expand macros in export blocks before exporting them.=C2=A0=C2= =A0

-Kevin
=C2=A0
--000000000000df8b8405e405212f--