HTML
  Home arrow HTML arrow Page 5 - Another Look at Animation of Geographical ...
Dev Articles Forums 
ADO.NET  
Apache  
ASP  
ASP.NET  
C#  
C++  
ColdFusion  
COM/COM+  
Delphi-Kylix  
Design Usability  
Development Cycles  
DHTML  
Embedded Tools  
Flash  
Graphic Design  
HTML  
IIS  
Interviews  
Java  
JavaScript  
MySQL  
Oracle  
Photoshop  
PHP  
Reviews  
Ruby-on-Rails  
SQL  
SQL Server  
Style Sheets  
VB.Net  
Visual Basic  
Web Authoring  
Web Services  
Web Standards  
XML  
Mobile Linux 
App Generation ROI 
IBM® developerWorks 
Sun Developer Network 
Weekly Newsletter
 
Developer Updates  
Free Website Content 
 RSS  Articles
 RSS  Forums
 RSS  All Feeds
Write For Us Get Paid 
Request Media Kit
Contact Us 
Site Map 
Privacy Policy 
Support 
 USERNAME
 
 PASSWORD
 
 
  >>> SIGN UP!  
  Lost Password? 
HTML

Another Look at Animation of Geographical Map Regions
By: Chrysanthus Forcha
  • Search For More Articles!
  • Disclaimer
  • Author Terms
  • Rating: 5 stars5 stars5 stars5 stars5 stars / 1
    2008-06-23

    Table of Contents:
  • Another Look at Animation of Geographical Map Regions
  • How to Stop the Blinking
  • Complete Code
  • Code continued
  • More Code

  • Rate this Article: Poor Best 
      ADD THIS ARTICLE TO:
      Del.ici.ous Digg
      Blink Simpy
      Google Spurl
      Y! MyWeb Furl
    Email Me Similar Content When Posted
    Add Developer Shed Article Feed To Your Site
    Email Article To Friend
    Print Version Of Article
    PDF Version Of Article
     
     
    ADVERTISEMENT


    Another Look at Animation of Geographical Map Regions - More Code


    (Page 5 of 5 )


    <area onmouseover="startTogglingPortugal()" href ="moreOnPortugal.htm" alt="Click to know more about tourism in Portugal" shape ="poly" coords ="21,317,19,323,21,329,20,331,19,330,18,334,13,343,10,346,8,350,9,
    356, 11,356,10,360,10,365,7,369,10,372,15,372,17,375,20,373,20,368,
    25,363,25, 358,27,354,26,351,26,348,27,346,30,344,33,338,33,336,33,
    333,33,332,37,331, 39,329,39,328,38,326,37,324,35,324,34,323,31,324,
    28,322,27,322,26,319,23, 319">

    <area onmouseover="startTogglingSpain()" href ="moreOnSpain.htm" alt="Click to know more about tourism in Spain" shape ="poly" coords ="21,319,26,319,26,322,30,322,32,322,38,325,40,328,38,330,33,333,31, 344,26,348,27,353,23,359,26,363,22,366,20,371,24,374,26,376,28,383,
    32,390, 37,384,42,384,44,383,48,383,51,384,55,384,58,387,60,385,63,
    387,71,379,76, 379,78,373,87,368,84,366,84,366,83,359,83,357,94,346,
    96,344,105,343,109,341,112,338,116,333,113,331,106,331,102,328,97,
    325,93,326,89,325,86,323,84,321,82,320,78,316,74,316,68,315,65,312,
    58,312,56,312,47,308,43,308,40,306,37,306,35,304,31,303,27,307,23,
    306,19,309,21,312,22,314,21,318">

    <area onmouseover="startTogglingFrance()" href ="moreOnFrance.htm" alt="Click to know more about tourism in France" shape ="poly" coords ="77,316,82,320,86,322,88,323,91,325,95,324,102,327,105,330,112,
    331,113, 325,117,323,120,320,123,319,127,321,131,326,138,326,139,
    326,143,323,146,319,148,318,149,316,145,315,144,312,144,308,141,
    304,145,302,145,299,145,296,143,291,141,291,140,292,138,294,139,291,
    140,288,141,285,144,282,145,280,147,280,149,276,149,272,150,268,153,
    265,153,264,149,263,146,261,141,258,136,258,132,254,128,252,127,251,
    120,251,121,246,122,245,119,243,119,241,117,240,115,240,112,241,111,
    247,109,250,105,251,101,254,100,256,97,255,91,253,90,251,88,252,88,
    254,88,258,85,260,80,259,78,257,74,255,72,255,71,255,69,258,69,263,
    67,266,2,267,75,271,79,272,82,276,84,286,85,293,85,300,82,308,79,313,
    78,316">

    <area onmouseover="resetAll()" shape ="poly" coords ="7,369,23,373,34,387,48,384,63,387,76,379,86,368,83,359,97,343,
    113,337, 117,322,130,320,137,325,150,317,146,312,143,304,146,297,
    144,291,140,291,149,280,153,264,127,249,123,249,122,244,115,239,
    109,249,99,253,88,249,87,259,71,254,67,264,77,272,85,287,84,297,77,
    315,65,312,46,309,33,302,21,304,21,319,20,328,12,345,6,350,11,356,9,
    367,2,366,2,1,324,4,323,418,2,417,2,366,6,369">

    </map>

    <img src="Spain.jpg" usemap ="#MS" id="Spain">

    <map id="MS">

    <area onmouseover="startTogglingPortugal()" href ="moreOnPortugal.htm" alt="Click to know more about tourism in Portugal" shape ="poly" coords ="21,317,19,323,21,329,20,331,19,330,18,334,13,343,10,346,8,350,
    9,356,11, 356,10,360,10,365,7,369,10,372,15,372,17,375,20,373,20,
    368,25,363,25,358,27,354,26,351,26,348,27,346,30,344,33,338,33,336,
    33,333,33,332,37,331,39,329,39,328,38,326,37,324,35,324,34,323,31,
    324,28,322,27,322,26,319,23,319">

    <area onmouseover="startTogglingSpain()" href ="moreOnSpain.htm" alt="Click to know more about tourism in Spain" shape ="poly" coords ="21,319,26,319,26,322,30,322,32,322,38,325,40,328,38,330,33,333,
    31,344, 26,348,27,353,23,359,26,363,22,366,20,371,24,374,26,376,28,
    383,32,390,37,384, 42,384,44,383,48,383,51,384,55,384,58,387,60,385,
    63,387,71,379,76,379,78,373,87,368,84,366,84,366,83,359,83,357,94,
    346,96,344,105,343,109,341,112,338,116,333,113,331,106,331,102,328,
    97,325,93,326,89,325,86,323,84,321,82,320,78,316,74,316,68,315,65,
    312,58,312,56,312,47,308,43,308,40,306,37,306,35,304,31,303,27,307,
    23,306,19,309,21,312,22,314,21,318">

    <area onmouseover="startTogglingFrance()" href ="moreOnFrance.htm" alt="Click to know more about tourism in France" shape ="poly" coords ="77,316,82,320,86,322,88,323,91,325,95,324,102,327,105,330,112,
    331,113, 325,117,323,120,320,123,319,127,321,131,326,138,326,139,
    326,143,323,146,319,148,318,149,316,145,315,144,312,144,308,141,
    304,145,302,145,299,145,296,143,291,141,291,140,292,138,294,139,
    291,140,288,141,285,144,282,145,280,147,280,149,276,149,272,150,
    268,153,265,153,264,149,263,146,261,141,258,136,258,132,254,128,
    252,127,251,120,251,121,246,122,245,119,243,119,241,117,240,115,
    240,112,241,111,247,109,250,105,251,101,254,100,256,97,255,91,253,
    90,251,88,252,88,254,88,258,85,260,80,259,78,257,74,255,72,255,71,
    255,69,258,69,263,67,266,72,267,75,271,79,272,82,276,84,286,85,293,
    85,300,82,308,79,313,78,316">

    <area onmouseover="resetAll()" shape ="poly" coords ="7,369,23,373,34,387,48,384,63,387,76,379,86,368,83,359,97,343,113,
    337, 117,322,130,320,137,325,150,317,146,312,143,304,146,297,144,291,
    140,291,149, 280,153,264,127,249,123,249,122,244,115,239,109,249,99,
    253,88,249,87,259,71,254,67,264,77,272,85,287,84,297,77,315,65,312,46,
    309,33,302,21,304,21,319,20,328,12,345,6,350,11,356,9,367,2,366,2,1,324,
    4,323,418,2,417,2,366,6,369">

    </map>

    <img src="France.jpg" usemap ="#MF" id="France">

    <map id="MF">

    <area onmouseover="startTogglingPortugal()" href ="moreOnPortugal.htm" alt="Click to know more about tourism in Portugal" shape ="poly" coords ="21,317,19,323,21,329,20,331,19,330,18,334,13,343,10,346,8,350,
    9,356, 11,356,10,360,10,365,7,369,10,372,15,372,17,375,20,373,20,
    368,25,363,25,358, 27,354,26,351,26,348,27,346,30,344,33,338,33,
    336,33,333,33,332,37,331,39,329,39,328,38,326,37,324,35,324,34,
    323,31,324,28,322,27,322,26,319,23,319">

    <area onmouseover="startTogglingSpain()" href ="moreOnSpain.htm" alt="Click to know more about tourism in Spain" shape ="poly" coords ="21,319,26,319,26,322,30,322,32,322,38,325,40,328,38,330,33,333,
    31,344, 26,348,27,353,23,359,26,363,22,366,20,371,24,374,26,376,28,
    383,32,390,37,384, 42,384,44,383,48,383,51,384,55,384,58,387,60,385,
    63,387,71,379,76,379,78,373,87,368,84,366,84,366,83,359,83,357,94,
    346,96,344,105,343,109,341,112,338,116,333,113,331,106,331,102,328,
    97,325,93,326,89,325,86,323,84,321,82,320,78,316,74,316,68,315,65,
    312,58,312,56,312,47,308,43,308,40,306,37,306,35,304,31,303,27,307,
    23,306,19,309,21,312,22,314,21,318">

    <area onmouseover="startTogglingFrance()" href ="moreOnFrance.htm" alt="Click to know more about tourism in France" shape ="poly" coords ="77,316,82,320,86,322,88,323,91,325,95,324,102,327,105,330,112,331,
    113, 325,117,323,120,320,123,319,127,321,131,326,138,326,139,326,143,
    323,146,319, 148,318,149,316,145,315,144,312,144,308,141,304,145,302,
    145,299,145,296,143,291,141,291,140,292,138,294,139,291,140,288,141,
    285,144,282,145,280,147,280,149,276,149,272,150,268,153,265,153,264,
    149,263,146,261,141,258,136,258,132,254,128,252,127,251,120,251,121,
    246,122,245,119,243,119,241,117,240,115,240,112,241,111,247,109,250,
    105,251,101,254,100,256,97,255,91,253,90,251,88,252,88,254,88,258,85,
    260,80,259,78,257,74,255,72,255,71,255,69,258,69,263,67,266,72,267,75,
    271,79,272,82,276,84,286,85,293,85,300,82,308,79,313,78,316">

    <area onmouseover="resetAll()" shape ="poly" coords ="7,369,23,373,34,387,48,384,63,387,76,379,86,368,83,359,97,343,113,337, 117,322,130,320,137,325,150,317,146,312,143,304,146,297,144,291,140,
    291,149,280, 153,264,127,249,123,249,122,244,115,239,109,249,99,253,88,
    249,87,259,71,254,67,264,77,272,85,287,84,297,77,315,65,312,46,309,33,
    302,21,304,21,319,20,328,12, 345,6,350,11,356,9,367,2,366,2,1,324,4,323,
    418,2,417,2,366,6,369">

    </map>

    <img src="westEuropeMap.jpg" usemap ="#MM" id="initial">

    <map id="MM">

    <area onmouseover="startTogglingPortugal()" href ="moreOnPortugal.htm" alt="Click to know more about tourism in Portugal" shape ="poly" coords ="21,317,19,323,21,329,20,331,19,330,18,334,13,343,10,346,8,350,9,356,
    11, 356,10,360,10,365,7,369,10,372,15,372,17,375,20,373,20,368,25,363,
    25,358,27,354, 26,351,26,348,27,346,30,344,33,338,33,336,33,333,33,332,
    37,331,39,329,39,328,38, 326,37,324,35,324,34,323,31,324,28,322,27,322,
    26,319,23,319">

    <area onmouseover="startTogglingSpain()" href ="moreOnSpain.htm" alt="Click to know more about tourism in Spain" shape ="poly" coords ="21,319,26,319,26,322,30,322,32,322,38,325,40,328,38,330,33,333,31,344, 26,348,27,353,23,359,26,363,22,366,20,371,24,374,26,376,28,383,32,390,37,
    384, 42,384,44,383,48,383,51,384,55,384,58,387,60,385,63,387,71,379,76,
    379,78,373, 87,368,84,366,84,366,83,359,83,357,94,346,96,344,105,343,109,
    341,112,338,116, 333,113,331,106,331,102,328,97,325,93,326,89,325,86,323,
    84,321,82,320,78,316,74,316,68,315,65,312,58,312,56,312,47,308,43,308,40,
    306,37,306,35,304,31,303, 27,307,23,306,19,309,21,312,22,314,21,318">

    <area onmouseover="startTogglingFrance()" href ="moreOnFrance.htm" alt="Click to know more about tourism in France" shape ="poly" coords ="77,316,82,320,86,322,88,323,91,325,95,324,102,327,105,330,112,331,113, 325,117,323,120,320,123,319,127,321,131,326,138,326,139,326,143,323,146,
    319, 148,318,149,316,145,315,144,312,144,308,141,304,145,302,145,299,145,
    296,143, 291,141,291,140,292,138,294,139,291,140,288,141,285,144,282,145,
    280,147,280, 149,276,149,272,150,268,153,265,153,264,149,263,146,261,141,
    258,136,258,132, 254,128,252,127,251,120,251,121,246,122,245,119,243,119,
    241,117,240,115,240,112,241,111,247,109,250,105,251,101,254,100,256,97,
    255,91,253,90,251,88,252,88,254,88,258,85,260,80,259,78,257,74,255,72,255,
    71,255,69,258,69,263,67,266,72,267,75,271,79,272,82,276,84,286,85,293,85,
    300,82,308,79,313,78,316">

    <area onmouseover="resetAll()" shape ="poly" coords ="7,369,23,373,34,387,48,384,63,387,76,379,86,368,83,359,97,343,113,337, 117,322,130,320,137,325,150,317,146,312,143,304,146,297,144,291,140,291,
    149, 280,153,264,127,249,123,249,122,244,115,239,109,249,99,253,88,249,87,
    259,71,254, 67,264,77,272,85,287,84,297,77,315,65,312,46,309,33,302,21,304,
    21,319,20,328,12, 345,6,350,11,356,9,367,2,366,2,1,324,4,323,418,2,417,2,
    366,6,369">

    </map>

    </td>

    </tr>

    </tbody>

    </table>


    </body>


    </html>


    Conclusion

    One way to give animation to a geographical map image is to put images of different presentations in layers. To animate, change the position of the layers. Producing a blinking (toggling) effect is a delicate process. In the second example, there were two functions for each clickable region. Browsers today do not have features for animating clickable regions in image-maps.

    This is a delicate tutorial. That is why I have given two functions for each clickable region. If I did not do this, you would have found the article difficult to understand. Commercial web pages would have many clickable regions, so having two functions for each region would take up too much space. Now that you understand what to do, you can decide whether to have only two functions for all the clickable regions. You will have to use variables (IDs) to identify the different clickable regions.

    Also note that the AREA elements for the images with colored regions each have the onmouseover event. Logically, this is not necessary. However, I have included it because of browser limitations.


    DISCLAIMER: The content provided in this article is not warranted or guaranteed by Developer Shed, Inc. The content provided is intended for entertainment and/or educational purposes in order to introduce to the reader key ideas, concepts, and/or product reviews. As such it is incumbent upon the reader to employ real-world tactics for security and implementation of best practices. We are not liable for any negative consequences that may result from implementing any information covered in our articles or tutorials. If this is a hardware review, it is not recommended to open and/or modify your hardware.

       · At last, you too can also do it.Chrys
       · Please give one tip for <div> with table in ie browesr
     

    HTML ARTICLES

    - Using a 3D HTML Table as a Recordset
    - Building a 3D HTML Table
    - Maximizing and Restoring HTML Images: Layer ...
    - Completing Construction of a Database Form w...
    - Maximizing and Restoring Images in a Tabular...
    - Building the Recordset for an HTML Database ...
    - Laying Out a Database Form with HTML
    - Tabular Database Form Functions with HTML
    - Tabular Database Forms with HTML
    - Using the Find Functions for HTML Database F...
    - Sorting for Database Forms with HTML
    - Edit and Other Database Form Functions with ...
    - More Database Form Functions with HTML
    - Database Form Functions with HTML
    - Using the HTML Table Element as a Recordset






    © 2003-2008 by Developer Shed. All rights reserved. DS Cluster 3 hosted by Hostway
    Stay green...Green IT