Hi there

I am in the same position.
I see you suggested a different script all together, from bassistance.de,
instead of the original one from
cssglobe.com/post/1695/easiest-tooltip-and-image-preview-using-jquery .

The one you suggested is much more than i need. Was anyone able to modify
the original script to allow the preview tooltip to not break the window
borders?

Thanks!

PS: my test URL: http://tinyurl.com/dnd8gb 





Jörn Zaefferer-2 wrote:
> 
> 
> It looks like you got an old version of the plugin. Try the latest
> release, it has built-in support for repositioning the tooltip at the
> viewport border:
> http://bassistance.de/jquery-plugins/jquery-plugin-tooltip/
> 
> Jörn
> 
> On Sat, Jan 24, 2009 at 11:26 PM, CNN_news <nagit...@gmail.com> wrote:
>>
>> Hello,
>>
>> I have a theme that shows a preview of the image that the mouse is
>> currently hovering over with a larger image using jquery tooltip.
>>
>> The problem is that it always places the preview on the right and if
>> the image is on the right side of the page the preview causes
>> horizontal scrolling,
>>
>> see for yourself:
>>
>> http://torontopersonalinjurylawyers.org
>>
>> Is it possible make the preview switch to the left side of the mouse
>> if the mouse if on the right side of the page (ie. past a certain
>> point in the x-axis),
>>
>>
>> Somebody posted this code as a solution but I have not been able to
>> implement it:
>>
>> -----------------------------------------------------------------------
>> Thanks a lot of the extremely useful script!
>>
>> To position the tooltip depending where you are, you need to rewrite
>> some of the code using the offset() property of jQUERY.
>>
>> var toolTipPosition = $(this).offset(); //Declare the Offset object
>> var offsetX = 0;
>> var offsetY = 0;
>> //Then in the hover property
>> $("#tooltip")
>> .css("top",( toolTipPosition.top - posiY) + "px")//Will set where the
>> link/thumbnail is horizontally
>> .css("left",( toolTipPosition.left + this.offsetWidth/2 + posiX) +
>> "px") /*Will be positioned to the middle of the link/thumbnail, you
>> can alway remove this.offsetWidth/2 to remove the middle placement
>> thing.*/
>> //Remove the mouseover function and your set!
>>
>> .fadeIn("fast");
>> -----------------------------------------------------------------------
>>
>>
>>
>> Thanks.
>>
> 
> 

-- 
View this message in context: 
http://www.nabble.com/tooltip---image-preview-does-not-respect-window-border-tp21646181s27240p21901828.html
Sent from the jQuery General Discussion mailing list archive at Nabble.com.

Reply via email to