use of html map tag

Im am using Visua Studio/VB.NET

The hml block:
 
   <img src="~/images/studentCouncil.jpg" alt="Student Councill" border="0"  width="500" height="400"  usemap="studentCouncil"/>

<map name="studentCouncil" id="studentcouncil">
<area shape="rect" coords="9,47 65,74" alt="President" href="president.aspx"  />
</map>

is not bringing up the jpg file referenced.



Whereas the commented out block does does.

 <!--
                <td style="height: 274px; background-color: #F9FCEE" align="center" valign="middle">
                       <asp:Image ID="studentCouncil" runat="server" Height="500px"
                        ImageUrl="~/Images/studentCouncil.jpg" Width="770px" ImageAlign="Middle"
                           BorderStyle="None" ForeColor="Red" />
   -->:

I get the warning ew "usemap="studentCounci" that file (studentCounci} is not found.

Whole markup page follows:

<%@ Page Language="VB" MasterPageFile="~/SiteTemplate.master" Title="Student Council" AutoEventWireup="false" CodeFile="default.aspx.vb" Inherits="_Default" %>

<asp:Content ID="Content1" ContentPlaceHolderID="ContentPlaceHolder1" Runat="Server">

AC
    <td>
<!--
<table border="0"  cellpadding="0" cellspacing="0" style="width: 770px; height: 500%">
 -->  
        <table border="0"  cellpadding="0" cellspacing="0" style="width: 1024px; height: 100%">
  <tr >
  <!--
              <td style="background-color: #F9FCEE" align="center" valign="middle">
   -->
                              <td style="height: 50px; background-color: #1e4533" align="center"
                    valign="middle">
                    &nbsp;
                   <asp:Label ID="lblHeader" runat="server" Font-Size="X-Large"
                   Text="Student Council" Font-Names="Verdana" ForeColor="White"
                       BackColor="#304F41" BorderStyle="None"></asp:Label>
               </td>
  </tr>

  <tr>
  <td>
  <!--
                <td style="height: 274px; background-color: #F9FCEE" align="center" valign="middle">
                       <asp:Image ID="studentCouncil" runat="server" Height="500px"
                        ImageUrl="~/Images/studentCouncil.jpg" Width="770px" ImageAlign="Middle"
                           BorderStyle="None" ForeColor="Red" />
   -->
   
   <img src="~/images/studentCouncil.jpg" alt="Student Councill" border="0"  width="500" height="400"  usemap="studentCouncil"/>

<map name="studentCouncil" id="studentcouncil">
<area shape="rect" coords="9,47 65,74" alt="President" href="president.aspx"  />
</map>
   
   
                </td>
  </tr>
  <tr>
                <td style="height: 20px; background-color: #F9FCEE" align="center"
                  valign="middle">
                      <asp:Label ID="Label3" runat="server" Font-Italic="True" Font-Size="Small"
                                                    ForeColor="Red"
                                                   
                                                    Text="note: orange denotes subject page, white denotes navigational hotspot to be"></asp:Label>
                </td>
  </tr>
  <tr>
                <td style="height: 20px; background-color: #F9FCEE" align="center" valign="middle">
                      <asp:Label ID="Label1" runat="server" Font-Italic="True" Font-Size="Small" ForeColor="Red"
                      Text="in work: org rectangles as hotspots for navigation, vision/mission statements, alignment and sizing issues">
                      </asp:Label>
                </td>
  </tr>
</table>
    </td>
</asp:Content>
hrj5721Asked:
Who is Participating?
 
Dave BaldwinFixer of ProblemsCommented:
Should be "usemap="#studentCouncil"" with the hash in front of it and the name spelled right.

http://www.w3schools.com/tags/att_img_usemap.asp
0
 
Dave BaldwinFixer of ProblemsCommented:
If 'Images' ('images' ?) is a subdirectory of the current directory, then you should be able to use "images/studentCouncil.jpg".  The difference may be that the other version is processed by ASP before it is sent to the browser.  Take a look at the "View Source" to see what actually ends up in the <img> tag.
0
 
hrj5721Author Commented:
clipping "~/" off src attribute worked in bringing up the desired webpage, thank you.

However Visual Studio complains about the usemap attribute map attribute, warning that "File studentCouncilMap cannot be Found."  (See first attachment)  The President" rectangle in the image (See second attachment} is not a hotspot.

My understanding is that "usemap="studentCouncilmap"" is referring to the following mapblock block of html, not to a file.

Please advise.
0
 
hrj5721Author Commented:
oops!

attachments
0
 
hrj5721Author Commented:
Thanks, much...
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.