[Date Prev][Date Next][Thread Prev][][Date Index][Thread Index]

Re: opening local files with arbitrary extensions as HTML


>>>>> In [emacs-w3m : No.09546] 
>>>>>	"Eduardo Ochs" <eduardoochs@xxxxxxxxx> wrote:
> Hi list,

> what is the recommended way to force w3m to open a local file as HTML?
> Here's an example: the first call to w3m below works, but the second
> one treats the local file as plain text and does not invoke w3m to
> render it as HTML...

>  (let ((w3m-async-exec nil))
>    (w3m "file:///usr/share/doc/galeon-common/FAQ.html"))

>  (let ((w3m-async-exec nil))
>    (w3m "file:///usr/share/doc/apache2-doc/manual/howto/cgi.html.en"))

> I've tried to find variables that I could set with "let" to force the
> "type" to "text/html", but the best that I was able to get was this:

>  (let ((w3m-content-type-alist '(("text/html" ""
> browse-url-default-browser nil))))
>    (let ((w3m-local-find-file-regexps '(nil . "")))
>      (let ((w3m-async-exec nil))
>        (w3m "file:///usr/share/doc/apache2-doc/manual/howto/cgi.html.en")
>      )
>    )
>  )

If your apache working, it might be better to access to

;; On debian, I'm using this way.

  Shinichiro HIDA  shinichiro@xxxxxxxxxxxxx
  GPG fingerprint = 5F2D 1656 FFF6 F691 A51C  5E61 E416 D398 470C 1CE9