America/US Samples
Europe Samples
Asia Samples

Gaia Ajax: ImageMap

The Gaia Ajax Image displays an image on a page. When a hot spot region defined within the ImageMap control is clicked, the control either generates an Ajax callback (postback) to the server or navigates to a specified URL. It inherits from the ASP.NET ImageMap, and has built-in Ajax behaviour.

SkyForestWater
Today's task: Roughly click the sky, the forest and the water on the image
Sky
Forest
Water

Markup (ASPX/.aspx)

   1:   
   2:  <div class="container-imagemap">
   3:      <gaia:ImageMap ID="zScenery" runat="server" ImageUrl="~/media/collections/images/scenery/summer_lake.jpg"
   4:          HotSpotMode="PostBack" OnClick="zScenery_Click">
   5:          <asp:RectangleHotSpot Bottom="160" Right="350" AlternateText="Sky"
   6:              PostBackValue="sky" />
   7:          <asp:RectangleHotSpot Bottom="180" Right="350" AlternateText="Forest"
   8:              Top="160" PostBackValue="forest" />
   9:          <asp:RectangleHotSpot AlternateText="Water" Bottom="263" Right="350"
  10:              Top="180" PostBackValue="water" />
  11:      </gaia:ImageMap>
  12:  </div>
  13:  <div class="container-todays-task">
  14:      <b>
  15:          Today's task: Roughly click the sky, the forest and the water on the image</b>
  16:      <gaia:Panel ID="zSky" runat="server" CssClass="answer-box answer-box-negative">
  17:          Sky
  18:      </gaia:Panel>
  19:      <gaia:Panel ID="zForest" runat="server" CssClass="answer-box answer-box-negative">
  20:          Forest
  21:      </gaia:Panel>
  22:      <gaia:Panel ID="zWater" runat="server" CssClass="answer-box answer-box-negative">
  23:          Water
  24:      </gaia:Panel>
  25:  </div>
  26:   
  27: