473,789 Members | 2,706 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Image panning code - Please help!

Hello,

I've customized the panview code to accommodate what I want it to do,
but I'm having a problem with it in IE. Firefox works fine.

Panning the image in IE doesn't work and I think it has something to
do with scrollTop, but i have no idea what to do to fix it. If I
take the pan image code out of the html page and have it by itself it
works.

I'd appreciate any help with this! Code and links are below.

Thank you!

Brady

The first thumbnail image is the to test.

With HTML: DOES NOT WORK
http://www.organizedmadness.com/pan/merchant.mvc.htm

Without HTML: WORKS

http://www.organizedmadness.com/pan/...t_mini.mvc.htm

"jQuery.fn.panv iew = function(target ){
num = 0;
return this.each(funct ion(){
new jQuery.panview( this,target);
});

}

jQuery.panview = function(obj,ta rget){
var bigImage = $("#"+target).g et(0);
$("img", obj).mouseover( function(){
MM_swapImage('m yimage','',this .src,
0);
var scaleY =
Math.round(bigI mage.offsetHeig ht/
this.offsetHeig ht);
var scaleX =
Math.round(bigI mage.offsetWidt h/this.offsetWidt h);
$("img", obj).mousemove( function(e){
this.style.curs or =
'pointer';
scrollY = e.pageY -
this.offsetTop - 10;
scrollX = e.pageX -
this.offsetLeft - 20;
bigImage.scroll Top =
scrollY * scaleY;
bigImage.scroll Left =
scrollX * scaleY;
});
});
$("img", obj).mouseout(f unction(){
$("img", obj).unbind("mo usemove");
MM_swapImgResto re();
bigImage.scroll Top=0;
bigImage.scroll Left=0;
});
}

Jun 6 '07 #1
2 2415
corymac <ai**********@H otmail.comwrote in news:1181149517 .295995.57090
@g37g2000prf.go oglegroups.com:
Hello,

I've customized the panview code to accommodate what I want it to do,
but I'm having a problem with it in IE. Firefox works fine.
you should probably hit up the jQuery support site
Jun 6 '07 #2
On Jun 6, 4:19 pm, Good Man <h...@letsgo.co mwrote:
corymac <airforcec...@H otmail.comwrote in news:1181149517 .295995.57090
@g37g2000prf.go oglegroups.com:
Hello,
I've customized the panview code to accommodate what I want it to do,
but I'm having a problem with it in IE. Firefox works fine.

you should probably hit up the jQuery support site
Yeah, I tried there already but didn't have any luck so I thought
maybe try here.
Thanks

Jun 6 '07 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
7027
by: Kurt | last post by:
Hi All, I'm just getting started rewriting a small CAD/GIS like application for designating outlines of objects in photographs/images in Python. Is there a class out there that already handles panning and zooming along with lines that have been drawn on top of the object? If got a simple scrolling canvas working and user designation of objects with the mouse. But I'm wondering if there is an elegant solution that handles zooming too. ...
15
31813
by: Anand Ganesh | last post by:
HI All, I have an Image. I want to clip a portion of it and copy to another image. How to do this? I know the bounding rectangle to clip. Any suggestions please. Thanks for your time and help. Regards
1
3210
by: Dan | last post by:
I must develop a (C-sharp) winforms application which should display some relatively large (e.g. 2~5 MB JPEG each) photographic images together with a rich set of related information: the application should allow the user to view each image with the 'standard' set of view features such as zooming in/out, panning, scrolling, etc. (of course without annoyances such as flickering and the like), and also offer image-map like functionality: for...
2
8570
by: Alberto | last post by:
I have an image loaded in a panel and I was trying to make a zoom on it. I still doesn't know how to do it but I was trying to access to the image loaded in the panel. Could you help me? Thank you.
6
8570
by: Saya | last post by:
Hello, This is a repost 'cause I haven't solve the problem: I can't use the System.Drawing class 'Image.FromStream' in the CompactFramework environment. What I've done with respect to Brendan's suggestion is as follows: Brendan, thanks for the reply! I'm a little bit further now, but not yet finished. I've come this far, see code below: Stream s =
1
2106
by: Adam | last post by:
I am having difficulty retrieving images from a SQL database. Here is the code I use to UPLOAD the image to the database: <form id="Form1" method="post" enctype="multipart/form-data" runat="server"> <INPUT id="UploadedImageFile" runat=server type="file" size="86"> </form>
15
5367
by: David Lozzi | last post by:
Howdy, I have a function that uploads an image and that works great. I love ..Nets built in upload, so much easier than 3rd party uploaders! Now I am making a public function that will take the path of the uploaded image, and resize it with the provided dimensions. My function is below. The current function is returning an error when run from the upload function: A generic error occurred in GDI+. Not sure what exactly that means. From what...
3
1457
by: pally546 | last post by:
Hi, i have a div with overflow set to hidden. I place an image larger than the div inside the div and the edges are 'chopped off' The problem is when I add a dragpanelextender OR a javascript drag function(wz_dragdrop) to the image, the image edges are no longer hidden, it's like the image has left the div entirely. I'm basically implementing a map and this is the panning function like google maps where you can drag the image around with...
4
6470
by: =?Utf-8?B?RnJhbmsgVXJheQ==?= | last post by:
Hi all I need to do a image viewer, just to view and zoom pictures in jpeg. I do not need to edit or save the picture. I am sure, there are some controls already made. I am thankful for any comment on that ! Best regards Frank Uray
0
9666
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
9511
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10410
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
9020
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
0
6769
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
5418
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
5551
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
2
3701
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
2909
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.