emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: Sebastian Rose <sebastian_rose@gmx.de>
To: emacs-orgmode Org-Mode <emacs-orgmode@gnu.org>
Subject: Re: Org publish hierarchies and style variable
Date: Wed, 29 Oct 2008 19:59:27 +0100	[thread overview]
Message-ID: <878ws7448g.fsf@kassiopeya.MSHEIMNETZ> (raw)
In-Reply-To: <87d4hj9zvm.fsf@fastmail.fm> (mdl@imapmail.org's message of "Wed, 29 Oct 2008 10:37:01 -0500")

Hi Matt,


The path problem could be addressed in a nice way:


#+STYLE: <base href="/" />


We may have several #+STYLE: lines, so we can add whatever we want to
the <head> section:


#+STYLE: <base href="/" />
#+STYLE: <?php require("some/code.php"); ?>
#+STYLE: <script type="text/javascript" language="JavaScript" src="jquery.js"></script>


The '<base href="" />' is _very_ interesting, all paths to
stylesheets, images (plus images in stylesheets!), flash films, applets
and scripts are resolved relative to this path by the browser!

This way, neither #+SETUPFILEs nor hard links are needed.





We could reuse the #+STYLE: option for everything related to HTML
export.

This would be easier on the maintainer (Carsten by now) then
adding an option for each and every feature we will request for HTML
publishing in the future.


Why didn't I think of it earlier???




Regards,

  Sebastian







mdl@imapmail.org writes:
> A question: The org-publish tutorial recommends the use of template
> files for setting the relative link to the stylesheet for nested
> directories to be published to html.
>  
> - http://orgmode.org/worg/org-tutorials/org-publish-html-tutorial.php
>
> E.g., 
>
> For first level directories such as 
>
>   ~/org/
>       |- css/
>       |  |- stylesheet.css
>       |- index.org
>       |- Emacs
>       |   |- index.org 
>                          
> ~/org/Emacs/index.org would contain the following:
>
> #+SETUPFILE: ~/.emacs.d/level-1.org
>
> which points to a setupfile with the option:
>
> #+STYLE: <link rel="stylesheet" type="text/css"\
>          href="../stylesheet.css" />
>
> My question: Instead of this method, which I find a little tedious,
> I've created a hardlink to the master css directory in each
> subdirectory of my project. As a result the, css files get copied to
> each subdirectory in my public web directory and I only need to
> specify a single style option in my org-publish-alist.
>
> Apart from taking up extra disk space on the server (and thus being
> less economical), are there any other potential problems with this
> approach? I'm using org as a wiki and have a lot of org files in each
> subdirectory. This approach seems easier than having to add and tweak
> the SETUPFILE option for each new org file. 
>
> ---
> Matt Lundin
> mdl at imapmail dot org
>
>
>
> _______________________________________________
> Emacs-orgmode mailing list
> Remember: use `Reply All' to send replies to the list.
> Emacs-orgmode@gnu.org
> http://lists.gnu.org/mailman/listinfo/emacs-orgmode
>

-- 
Sebastian Rose, EMMA STIL - mediendesign, Niemeyerstr.6, 30449 Hannover

Tel.:  +49 (0)511 - 36 58 472
Fax:   +49 (0)1805 - 233633 - 11044
mobil: +49 (0)173 - 83 93 417
Email: s.rose emma-stil de, sebastian_rose gmx de
Http:  www.emma-stil.de

      parent reply	other threads:[~2008-10-29 17:57 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-10-29 15:37 Org publish hierarchies and style variable mdl
2008-10-29 17:59 ` Bernt Hansen
2008-10-30  3:00   ` Matthew Lundin
2008-10-30 10:38     ` Richard Riley
2008-10-30 15:19       ` Sebastian Rose
2008-10-30 15:06         ` Richard Riley
2008-10-30 17:32           ` Sebastian Rose
2008-10-30 17:04             ` Richard Riley
2008-10-29 18:40 ` Sebastian Rose
2008-10-29 18:59 ` Sebastian Rose [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.orgmode.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=878ws7448g.fsf@kassiopeya.MSHEIMNETZ \
    --to=sebastian_rose@gmx.de \
    --cc=emacs-orgmode@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).