Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 750817
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 14, 20262026-05-14T14:35:40+00:00 2026-05-14T14:35:40+00:00

I have a requirement to allow users in a content management system to create

  • 0

I have a requirement to allow users in a content management system to create their own image maps through a gui interface, which I have accomplished. But instead of saving the image map to the page code, I want to save the image map code to a database (sql), which I’ve also accomplished.
When I started down this road in my head I was thinking the whole time that I’d just add the “usemap” attribute at runtime shown below where promo1.ImageMap holds the entire map code:


if(promo1.HasImageMap) imgPromotion1.Attributes.Add("usemap", promo1.ImageMap);

I guess I didn’t think it though well enough, because it seems that “usemap” only expects the name of the existing map to use from the page code, and not the map code as a string.

Does anyone have any clever ideas on how to apply the map from the database to the image at run time?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-14T14:35:40+00:00Added an answer on May 14, 2026 at 2:35 pm

    You can add a placeholder somewhere on the page and add the imagemap to it from the table when you load it, like the following (note that I’m assuming that promo1.ImageMap is a string that contains the entire imagemap, e.g. <map name=”imageMapName” … </map>):

    placeHolder.Controls.Add(new LiteralControl(promo1.ImageMap));
    

    Then, in your code, ensure that the image references the proper name in its usemap attribute:

    if(promo1.HasImageMap) 
        imgPromotion1.Attributes.Add("usemap", "#imageMapName");
    

    (Make sure that you use the hatch (pound sign) when referring to the imagemap name whenn adding the attribute.)

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have the requirement to allow users to view the content of a document
I have a requirement to allow users to open word document from web page
I have a requirement to allow users to browse directories on our file server,
I have requirement where I need to allow users to upload a Word document
I have a web page that has a requirement to allow users to paste
I have a requirement to create a simple windows forms application that allows an
I have requirement to get Facebook friends list with their images. How can I
I have a requirement where i need to allow only numbers in text box.
I have a requirement for my web app to allow the user to Print
I want to allow users to create tiny templates that I then render in

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.