NetTalk Central

Author Topic: Lookup from image map/hotspot  (Read 2433 times)

Ubaidullah

  • Full Member
  • ***
  • Posts: 123
    • View Profile
Lookup from image map/hotspot
« on: December 05, 2010, 10:20:27 AM »
Hi,

Instead of presenting a list to select from, I want to display an image of a plant and depending on where in the image the user clicked, fill a field with a corresponding value.

How do I go about doing this?

Thanks & Regards,
Ubaidullah Nubar.


Rene Simons

  • Hero Member
  • *****
  • Posts: 649
    • View Profile
Re: Lookup from image map/hotspot
« Reply #1 on: December 06, 2010, 01:28:13 AM »
Hi Ubaidullah,

First you have to "map" all the different areas in each image and asign a URL to these areas.
The URL will have to take care of filling the field.

A simple but effective image mapping program can be found at
http://www.coffeecup.com/image-mapper/

Regards,
Rene
Rene Simons
NT14.14

Ubaidullah

  • Full Member
  • ***
  • Posts: 123
    • View Profile
Re: Lookup from image map/hotspot
« Reply #2 on: December 06, 2010, 07:12:41 AM »
Hi Rene,

Thanks for the reply.

I got the part about mapping the areas. What I need to figure out is how to fill a field based on the area clicked.

Also, thanks for the link.

Thanks & Regards,
Ubaidullah Nubar.

Rene Simons

  • Hero Member
  • *****
  • Posts: 649
    • View Profile
Re: Lookup from image map/hotspot
« Reply #3 on: December 07, 2010, 03:42:05 AM »
Hi Ubaidullah,

In the image mapping you can put the URL of the page itself with attached a variable name and a value.
E.g.

MyPlantPage?plantPart="Description of the plant part."

In the MyPlantPage (which I presume is a form) in the upper part of the GenerateForm routine, you do a p_web.storeValue('plantPart').

On the page itself you define a DisplayField with text-property p_web.gsv('PlantPart')
You can also this field like: p_web.gsv('plantPart') <> ''

I haven't tried this out but it might work. Maybe someone else knows a solution which is much simpler. Who knows...

Rene
Rene Simons
NT14.14