Skip to content

fhmoralles/imagemap

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 

Repository files navigation

imagemap

imagemap is a Javascript library for work with image as map. jQuery is required. The goal is to create a simple core library that can be customized and extended.

Current version

0.0.5.0

Demo

Quick Start

  1. Import JQuery <script type="text/javascript" src="jquery.min.js"></script>
  2. Import ImageMap javascript file <script type="text/javascript" src="imageMap.js"></script>

Example

  1. Creating a map
var map = new imagemap.Map({
  container: 'map',
  image: 'path/to/image/map_image.png',
  size: [4660, 3050],
  zoom: 9,
  nivel: 19
});
Atribute Explanation
container Div to create map
image Path to image
size Imagem original size [ W, H ]
zoom Zoom imagem start
nivel Max zoom level
  1. Creating a marker
var marker1 = map.addMarker({
  image: 'marker_red.png',
  position: [680, 720]
});
Atribute Explanation
image Makert path to image
position Marker position on original imagem [ Left, Top ]
width Marker width
height Marker height
reference Users value control
description Users description
onclick Marker onclick event

Authros

Fernando Moralles

Copyright

License

Releases

No releases published

Packages

No packages published