Fullsize FAQs

6 views
Skip to first unread message
Message has been deleted

Fullsize

unread,
Apr 1, 2009, 5:22:28 PM4/1/09
to Fullsize
** Why do would you want to add a fullsize attribute, can't you just
use Javascript?

The Fullsize attribute would be designed to make a common practice
(image popups) a breeze to setup and use.
You will still always be able to use your own javascript method if you
choose. But if you would like to quickly provide this functionality,
that is what Fullsize would be for. Remember that fullsize would only
be active if the IMG tag has a fullsize attribute. If you do not add
in the fullsize attribute, you can use javascript in it's place.

---------------------------------

** If Javascript is turned off would fullsize be broken?

I am proposing that Fullsize be supported natively by the browser. So
if javascript is on or off… it is irrelevant.

---------------------------------

** I would not want this kind of thing controlled by the browser,
because then I would have no control over how it looks.

If fullsize is added to the next version of HTML, there cold be CSS
support for this. Please check out all the details here:
http://groups.google.com/group/fullsize/browse_thread/thread/7b7d539bb6448072

I do not see the need for the additional CSS support. If you don't
like the way the browser displays it, use javascript. Though it would
be nice to have the CSS support, I do not see it as necessary.

---------------------------------

kingkool68

unread,
Apr 1, 2009, 9:00:13 PM4/1/09
to Fullsize
Ok so what happens if a link is wrapped around an image with a
fullsize attribute? Does the link event override the fullsize event?

On Apr 1, 5:22 pm, Fullsize <d...@drewwilson.com> wrote:
> ** Why do would you want to add a fullsize attribute, can't you just
> use Javascript?
>
> The Fullsize attribute would be designed to make a common practice
> (image popups) a breeze to setup and use.
> You will still always be able to use your own javascript method if you
> choose. But if you would like to quickly provide this functionality,
> that is what Fullsize would be for. Remember that fullsize would only
> be active if the IMG tag has a fullsize attribute. If you do not add
> in the fullsize attribute, you can use javascript in it's place.
>
> ---------------------------------
>
> ** If Javascript is turned off would fullsize be broken?
>
> I am proposing that Fullsize be supported natively by the browser. So
> if javascript is on or off… it is irrelevant.
>
> ---------------------------------
>
> ** I would not want this kind of thing controlled by the browser,
> because then I would have no control over how it looks.
>
> If fullsize is added to the next version of HTML, there cold be CSS
> support for this. Please check out all the details here:http://groups.google.com/group/fullsize/browse_thread/thread/7b7d539b...

Fullsize

unread,
Apr 2, 2009, 10:29:13 AM4/2/09
to Fullsize
kingkool68,

That is answered in the video as well as on the website. Please watch
the videos and read the website.
One of the example images I posted on the website IS wrapped in a
link. Go try it out.
The image will still link to the appropriate URL, but if you click on
the fullsize icon it will display the popup.
Please watch the second video at the bottom of the website, it
describes this in detail.
Thanks so much!

Drew Wilson

Bornhall

unread,
Apr 6, 2009, 7:50:06 AM4/6/09
to Fullsize
I was looking for something more or less exactly like this, although I
don't fully agree with the implementation and intentions of adding a
fullsize attribute to the HTML specs. Here are a few thoughts from me:

1. First off, I respect your tries to get a fullsize attribute
implemented in the HTML specs. I do not however think it will solve
anything anytime soon even if it did, and I'm not so sure the goal for
HTML includes something like this. But that's my opinion.

2. I question the use of the longdesc attribute for this. The
intention of that attribute is very close to what you use it for, but
not quite what was intended. I don't fully know if ANY browser (I'm
not keeping track of specialized browsers for various handicaps)
supports the longdesc attribute as it is intended. Would it be
possible to add functionality to skip the longdesc attribute and make
use of surrounding <a></a> tags to pick up a link to the full size
image? Of course, this should be an option, but it would solve issues
with browsers with javascript disabled for whatever reason. In that
case a <a href="bigpicture.jpg"><img src="littlepic.jpg"></a> is more
reliable and degrades nicely. Get the href from the surrounding <a>
tag and use that instead of longdesc. That would be my preferred
method at least.

3. I went in and added a pageMargin option, so you can manually tell
how much space you want from the viewport edges to where your fullsize
image appears. I simply replaced the hardcoded 30 pixels with
opts.pageMargin instead. Maybe something you should add to your
release version?

4. I tried manually wrapping the <img> tag in <a></a>, but I haven't
gotten it to work quite yet (don't know why, but it's not clickable
for some reason). To do this I added a clickThrough option (true/
false) that wraps the full size image in <a></a> IF and only if the
full size image doesn't fit inside the viewport. If it fits, it just
displays it, if it doesn't fit however, the fullsize-displayed image
in itself would link to the full size image and if clicked display it
by itself in a _blank browser window.

Here's most of my edits:

img_scaled = false;
if ((img_w + opts.pageMargin) > win_w) {
img_w = win_w - opts.pageMargin;
img_h = img_w / aspect;
img_scaled = true;
}
if ((img_h + opts.pageMargin) > win_h) {
img_h = win_h - opts.pageMargin;
img_w = img_h * aspect;
img_scaled = true;
}

...

if(opts.clickThrough && img_scaled) {
var link_image = $("<a></a>").attr("src",img_src).attr
("target","_blank");
$(link_image).prepend(this);
$(full_wrap).prepend(link_image);
} else {
$(full_wrap).prepend(this);
}

A bit quick and dirty, but the produced HTML seems proper, but as I
said; for some reason the <a> tag can't be clicked (no hand pointer
even). Of course, such a solution would obviously need some kind of
closing mechanism if the title bar isn't present, or the functionality
could possible be to overlay further icons on top of the fullsize
image (show on hover, hide on mouse movement) to close the full size
image or to (if applicable) open the really full size image in a
separate browser window.

Basically, I'm looking for the following:

a) No javascript: displays the standard <a href="bigpicture.jpg"><img
src="littlepic.jpg"></a>. Degrades fully and works for basically
everything.

b) Full size image fits within the browser's viewport: clicking the
littlepic.jpg brings up the bigpicture.jpg which your script picks up
from the surrounding <a> tag's href attribute OR the longdesc
attribute, depending on which the web developer choose to use.

c) Full size image does NOT fit within the browser's viewport: same as
b above, but with the added option to allow the visitor to click
through to the full image if he/she wants to. This image would open by
itself (no wrapping of any kind) in a new browser window. Preferably
you'd be able to specify the target attribute for the <a> tag that is
programmatically inserted by fullsize.

My suggestions in short:
• Add a "pageMargin" option. Easily done, I'm surprised it isn't in
there already.
• Add a fallback option to use surrounding <a> tag to pick up the full
size image from its href attribute.
• Add an option "clickThrough" (true/false) and "clickTarget" (window
name) that allows images that still does not fit to be viewed in full.

Hope these suggestions are of interest to you! Keep up the good
work :-)

Bornhall

unread,
Apr 6, 2009, 7:54:33 AM4/6/09
to Fullsize
Oh, one more little thing. I've experienced (Firefox 3.0.8) that the
generated content isn't always removed when the image closes and zooms
back to its original position and size. I'm using standard values for
fullsize. Maybe a delayed extra check to remove it would be in order?
If it leaves stuff lying around, I think most developers will find
another plugin or roll their own.

Bornhall

unread,
Apr 6, 2009, 8:09:02 AM4/6/09
to Fullsize
Of course, I could start by using the href attribute in <a> instead of
src... duh

Fullsize

unread,
Apr 7, 2009, 12:22:20 PM4/7/09
to Fullsize
Bornhall,

Thanks for taking the time to leave your thoughts about Fullsize.

I do not think I will ever add the ability for Fullsize to work with
the <a> tag. That defeats the whole purpose of Fullsze.
The nice thing about using the <img> tag to describe where the
Fullsize image is located, is that you can link the image to another
page or website, and the Fullsize popup will still work as well.
Try not to think of Fullsize as a <a> link, because it is not. It is
another ATTRIBUTE of the <img> tag. So it should behave as one, and
not take on the responsibilities of the <a> tag.

On your suggestions for "b" and "c".. I do not think I will implement
those either. Simply because that can be achieved by "destroying"
Fullsize on the element you don't want it to work with.

Again, thanks so much for taking the time and I will look into added
you margin suggestion.

Peace,
Drew
Reply all
Reply to author
Forward
0 new messages