emacs-orgmode
[Top][All Lists]
Advanced

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

Re: [O] Confused about inline html images


From: John Hendy
Subject: Re: [O] Confused about inline html images
Date: Sun, 13 Jan 2013 14:09:15 -0600

On Sun, Jan 13, 2013 at 1:54 PM, John Hendy <address@hidden> wrote:
> On Sun, Jan 13, 2013 at 1:48 PM, John Hendy <address@hidden> wrote:
>> I'm trying to recreate this html:
>>
>> <a href="http://path/to/image.jpg";><img src="http://path/to/image.jpg";
>> width="400px" /></a>
>>
>> My approach was like so:
>>
>> #+attr_html: width="400px"
>> [[http://path/to/image.jpg][http://path/to/image.jpg]]
>>
>> From the description at using inline images
>> (http://orgmode.org/manual/Images-in-HTML-export.html):
>>
>> #+begin_quote
>> If the description part itself is a file: link or a http: URL pointing
>> to an image, this image will be inlined and activated so that clicking
>> on the image will activate the link. For example, to include a
>> thumbnail that will link to a high resolution version of the image,
>> you could use:
>>
>>      [[file:highres.jpg][file:thumb.jpg]]
>> #+end_quote
>>
>> That sounds like my example above should work; the example indicates
>> that thumb.jpg would be inlined and clicking it would send to
>> highres.jpg. I'd like http://path/to/image.jpg to be inlined at 400px
>> but clicking it would make the full size jpg viewable in a browser.
>>
>> I haven't changed the variable org-export-html-inline-images. It
>> should be set to the default, which appears to be 'maybe.'
>>
>
> As usual (right after tinkering a lot and finally mailing the list),
> this seems to have just started working, so I'll chalk that up to
> something I goofed in my bracket syntax perhaps?

Just kidding. Still getting finnicky results, and don't know why. I'm
getting either:

1) full sized inline image that *does* click/link

2) a properly sized image that does not click/link. Copied directly
from org-mode to make sure I'm not goofing something up by re-writing
the syntax since I can't see it when it's in link-formatted face:

[[http://path/to/image.jpg][http://path/to/image.jpg]]

Produces:

<img src="http://path/to/image.jpg"; width="400px"
alt="http://path/to/image.jpg"; />

I can't get it to reproduce the big (but properly linked) image
mentioned below at the moment.


John

>
> Still one issue: it's applying the attr_html to the wrong bit. Here's
> the resultant export output:
>
> #+attr_html: width="400px"
> [[http://path/to/file.jpg][http://path/to/file.jpg]]
>
> becomes:
>
> <a href="http://path/to/file.jpg"; width="400px"><img
> src="http://path/to/file.jpg"; alt="file.jpg"/></a>
>
> So the width attr is passed to the link section, not the the img.
>
> Is this a bug?
>
>
> Thanks,
> John
>
>>
>> Thanks for any suggestions,
>> John



reply via email to

[Prev in Thread] Current Thread [Next in Thread]