emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
* Link to a local html file
@ 2009-06-29 13:43 Nicolas Girard
  2009-06-29 14:18 ` Sebastian Rose
                   ` (2 more replies)
  0 siblings, 3 replies; 5+ messages in thread
From: Nicolas Girard @ 2009-06-29 13:43 UTC (permalink / raw)
  To: emacs-orgmode

Hi,

how to create a link to a local html file, say, /path/to/file.html, so
that clicking on it opens the page in a browser ?

Thanks in advance,
Nicolas

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Link to a local html file
  2009-06-29 13:43 Link to a local html file Nicolas Girard
@ 2009-06-29 14:18 ` Sebastian Rose
  2009-06-29 14:20 ` Manish
  2009-06-29 14:20 ` Bastien
  2 siblings, 0 replies; 5+ messages in thread
From: Sebastian Rose @ 2009-06-29 14:18 UTC (permalink / raw)
  To: Nicolas Girard; +Cc: emacs-orgmode

Nicolas Girard <nicolas.girard@nerim.net> writes:
> Hi,
>
> how to create a link to a local html file, say, /path/to/file.html, so
> that clicking on it opens the page in a browser ?


If you serve that file through a webserver (here apache2), you could do
something like this:

   [[http://localhost/~user/path/to/file.html][file.html]]


I serve several directories in my home directory to either localhost
only, or to the intranet here. You simply can add entries to your
/etc/apache2/httpd.conf (on GNU/Linux) like this:


    Alias /devel "/home/sebastian/develop/htdocs"
    <Directory "/home/sebastian/develop/htdocs">
        Options Indexes MultiViews
        Order allow,deny
        Allow from 192.168.178.0/255.255.255.0
        Allow from 127.0.0.1
    </Directory>


...and adjust the network as needed.



     Sebastian

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Link to a local html file
  2009-06-29 13:43 Link to a local html file Nicolas Girard
  2009-06-29 14:18 ` Sebastian Rose
@ 2009-06-29 14:20 ` Manish
  2009-06-29 14:20 ` Bastien
  2 siblings, 0 replies; 5+ messages in thread
From: Manish @ 2009-06-29 14:20 UTC (permalink / raw)
  To: Nicolas Girard; +Cc: emacs-orgmode

  On Mon, Jun 29, 2009 at 7:13 PM, Nicolas
Girard<nicolas.girard@nerim.net> wrote:
  > Hi,
  >
  > how to create a link to a local html file, say, /path/to/file.html, so
  > that clicking on it opens the page in a browser ?

One way to define a link to a file.

--8<---------------cut here---------------start------------->8---
[[~/agenda.html][Agenda]]
--8<---------------cut here---------------end--------------->8---

Following settings from .emacs open the link in a new Firefox tab.

--8<---------------cut here---------------start------------->8---
 '(browse-url-browser-function (quote browse-url-firefox))
 '(browse-url-firefox-new-window-is-tab t)
--8<---------------cut here---------------end--------------->8---

C-c C-o opens the link.

HTH
-- 
Manish

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Link to a local html file
  2009-06-29 13:43 Link to a local html file Nicolas Girard
  2009-06-29 14:18 ` Sebastian Rose
  2009-06-29 14:20 ` Manish
@ 2009-06-29 14:20 ` Bastien
  2009-06-29 15:26   ` Bastien
  2 siblings, 1 reply; 5+ messages in thread
From: Bastien @ 2009-06-29 14:20 UTC (permalink / raw)
  To: Nicolas Girard; +Cc: emacs-orgmode

Nicolas Girard <nicolas.girard@nerim.net> writes:

> how to create a link to a local html file, say, /path/to/file.html, so
> that clicking on it opens the page in a browser ?

1. C-u C-c C-l to insert a link to a local file
2. C-u C-u to open the link in an external browser

Also check M-x customize-variable RET org-file-apps RET

HTH,

-- 
 Bastien

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Link to a local html file
  2009-06-29 14:20 ` Bastien
@ 2009-06-29 15:26   ` Bastien
  0 siblings, 0 replies; 5+ messages in thread
From: Bastien @ 2009-06-29 15:26 UTC (permalink / raw)
  To: Nicolas Girard; +Cc: emacs-orgmode

Bastien <bastienguerry@googlemail.com> writes:

> Nicolas Girard <nicolas.girard@nerim.net> writes:
>
>> how to create a link to a local html file, say, /path/to/file.html, so
>> that clicking on it opens the page in a browser ?
>
> 1. C-u C-c C-l to insert a link to a local file
> 2. C-u C-u to open the link in an external browser

Oops: 

2. C-u C-u C-c C-o to open the link in an external browser

... which is only required for .php files, for example.  
.html links should work with C-c C-o, as other replies said.

-- 
 Bastien

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2009-06-29 15:26 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-06-29 13:43 Link to a local html file Nicolas Girard
2009-06-29 14:18 ` Sebastian Rose
2009-06-29 14:20 ` Manish
2009-06-29 14:20 ` Bastien
2009-06-29 15:26   ` Bastien

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).