Solved

JQuery transition problems

Posted on 2014-09-22
4
193 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

Master Your Team's Linux and Cloud Stack

Come see why top tech companies like Mailchimp and Media Temple use Linux Academy to build their employee training programs.

Question has a verified solution.

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

This is a PowerShell web interface I use to manage some task as a network administrator. Clicking an action button on the left frame will display a form in the middle frame to input some data in textboxes, process this data in PowerShell and display…
This article discusses how to create an extensible mechanism for linked drop downs.
In this tutorial viewers will learn how to embed videos in a webpage using HTML5. Ensure your DOCTYPE declaration is set to HTML5: "<!DOCTYPE html>": Use the <video> tag to insert a video. Define the src as the URL of your video; this is similar to …
The viewer will the learn the benefit of plain text editors and code an HTML5 based template for use in further tutorials.

860 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