www.webdeveloper.com
Recent Articles
  • Finding Slow Running Queries in ASE 15
  • A More Advanced Pie Chart for Analysis Services Data
  • Adobe AIR Programming Unleashed: Working with Windows
  • Performance Testing SQL Server 2008's Change Data Capture Functionality
  • The ABC's of PHP: Introduction to PHP
  • How to Migrate from BasicFiles to SecureFiles Storage
  • Why the Twitter Haters Are Wrong
  • User Personalization with PHP: Beginning the Application
  • Whats in an Oracle Schema?
  • Lighting Enhancement in Photoshop
  •  

    Go Back   WebDeveloper.com > Client-Side Development > JavaScript

    JavaScript JavaScript (not Java) Discussion and technical support, including AJAX and frameworks (JQuery, MooTools, Prototype...)

    Reply
     
    Thread Tools Search this Thread Rate Thread Display Modes
      #1  
    Old 11-20-2009, 12:31 PM
    crmpicco crmpicco is offline
    Registered User
     
    Join Date: Apr 2006
    Posts: 200
    Question jQuery/z-index issue with displaying GIFs

    Hi,

    I am having an issue with the 'Click To Zoom' image which should appear at the bottom left hand corner of the main image on this page - http://bit.ly/4z8dNm

    If you click the image, there will be a 'Click To Zoom Out' image appear, then if you click again the 'Click To Zoom' image WILL appear. But this should appear on initial load. The image is http://bit.ly/4o2WCj - so it's definately on the server.

    It doesn't appear to be browser specific, it happens on FF and IE.

    My jQuery that I believe may be the point to look at is:
    Code:
    jQuery('#large_look').toggle(function(e){
    	
    		imgBig = jQuery('.zoomin_container IMG');
    		zoomBtn = jQuery('.zoom_image');
    		ratio = (imgBig.width() - imgSmall.width()) / imgSmall.width();
    		
    		imgBig.css({
    		'width' : 320,
    		'height' : 422,
    		'top':0,
    		'left':0,
    		'z-index' : 99
    		});
    		
    		imgBig.animate({
    		'left'		: (0 - ((e.pageX - imgSmallOffsetLeft) * ratio)) + 'px',
    		'top'		: (0 - ((e.pageY - imgSmallOffsetTop) * ratio)) + 'px',
    		'width'		: 1896,
    		'height'	: 2500 
    		}, 'slow');
    		
    		
    		zoomBtn.css({
    			'color'			: 'blue',
    			'background'	: 'url(/assets/lookbook/Zoom_Out_btn.gif)',
    			'z-index'		: 100
    		});
    		
    		isZoomed = true;
    		return false;
    		
    		},function(){
    		
    		isZoomed = false;
    		zoomBtn.css({
    			'background'	: 'url(/assets/lookbook/Zoom_In_btn.gif)'			
    		});
    		
    		imgBig.fadeOut("slow");
    	});
    Any help appreciated.

    Cheers,
    Picco
    Reply With Quote
    Reply

    Bookmarks


    Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
     
    Thread Tools Search this Thread
    Search this Thread:

    Advanced Search
    Display Modes Rate This Thread
    Rate This Thread:

    Posting Rules
    You may not post new threads
    You may not post replies
    You may not post attachments
    You may not edit your posts

    BB code is On
    Smilies are On
    [IMG] code is Off
    HTML code is Off
    Forum Jump


    All times are GMT -5. The time now is 09:04 PM.



    Acceptable Use Policy


    The Network for Technology Professionals

    Search:

    About Internet.com

    Legal Notices, Licensing, Permissions, Privacy Policy.
    Advertise | Newsletters | E-mail Offers

    Powered by vBulletin® Version 3.7.3
    Copyright ©2000 - 2010, Jelsoft Enterprises Ltd.