Solved

JQuery transition problems

Posted on 2014-09-22
4
189 Views
Last Modified: 2014-09-28
I am working on replacing an old piece of FLASH code which is a simple click and zoom map with three stages (images).

Basically, I had this working where the old map zoomed forwards like you were falling into the map, and then the other zooms in, but there is a requirement (because this is how it USED to work) to have it so that when the new maps come in, they overwrite the old map, as opposed to blanking it out. I have included the old SWF below.

I am using the transit plugin for the animations

So I have set the map to scale in from a small state (all transitions are done using the transit plugin, but for some reason it is blanking out the div it is overwriting before it gets to full screen. It is almost as though.. even though the DIV is scaled, the container is the full size and just filled with nothing

Here is the old FLASH version we are trying to supercede.

SWF Version

I have uploaded my HTML5 'attempt' to JSFiddle

My Attempt on JSFIddle

You will need to expand the RUN box to fit the whole map before you can see the first CLIKC HERE button

When you click on the CLICK HERE button, the next map scales in with a new button, click it again to get a closer map and then you are taken to another page (currently set to google). Even though it is not set to do so, the DIVS that are zooming in are blanking the one underneath.

I am sure (as this was a quick job) I have gone about this all wrong but any or all guidance to getting this final piece of the puzzle in place will be greatly appreciated
0
Comment
Question by:mvwmail
  • 3
4 Comments
 
LVL 82

Assisted Solution

by:leakim971
leakim971 earned 100 total points
ID: 40339455
if I can help :
you should train doing it with two images, one with zoom -100000 and the other one
both should have CSS :
position: absolute

once you click on the area of the visible one, you DON'T  hide it, but just append the second one too zoom to the right place (use CSS left,top to set tehe position to clicked region) and use jQuery.animate( {width:$( window ).width(), top:0, left:0}, "slow")
0
 
LVL 3

Accepted Solution

by:
mvwmail earned 0 total points
ID: 40340244
Finally got there by nesting the divs, this allowed overwriting without blanking out

Final Fiddle!
0
 
LVL 3

Author Comment

by:mvwmail
ID: 40340257
The correct URl to the final asnwer

The Final Solution
0
 
LVL 3

Author Closing Comment

by:mvwmail
ID: 40348382
Appreciate you taking the time, and indirectly I used your technique just with divs

http://jsfiddle.net/MOLEDesign/L5b67ptn/
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

So you have coded your own WordPress plugin and now you want to allow users to upload images to a folder in the plugin folder rather than the default media location? Follow along and this article will show you how to do just that!
Use these top 10 tips to master the art of email signature design. Create an email signature design that will easily wow recipients, promote your brand and highlight your professionalism.
In this tutorial viewers will learn how to code links for mobile sites that, once clicked, send a call or text to a specified number. For a telephone link (once clicked, calls a number), begin with a normal "<a href=" link tag. For the href, specify…
In this tutorial viewers will learn how to style a corner ribbon overlay for an image using CSS Create a new class by typing ".Ribbon":  Define the class' "display:" as "inline-block": Define its "position:" as "relative": Define its "overflow:" as …

911 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

26 Experts available now in Live!

Get 1:1 Help Now