var pins_config = {
"pins":[
{
"shape": "circle",//either "circle" or "square"
"hover": "GCF Beirut
Beirut, Lebanon
Istiklal Street
Karout Building | 2nd & 3rd Floor
",//info of the popup
"pos_X": 560,//check the X, Y coordinates guide in the documentation
"pos_Y": 355,
"size": 18,//size of the pin
"outline": "#000080",//outline color of the pin
"upColor": "#00cc00",//color of the pin when map load
"overColor": "#fff700",//color of the pin when mouse hover
"url": "#",//link to any webpage
"target": "none",// use "new_window", "same_window", "modal", or "none"
"active": true//true/false to activate/deactivate this pin
}
, {
"shape": "circle",//either "circle" or "square"
"hover": "GCF Cairo
Cairo, Egypt
",//info of the popup
"pos_X": 550,//check the X, Y coordinates guide in the documentation
"pos_Y": 370,
"size": 18,//size of the pin
"outline": "#000080",//outline color of the pin
"upColor": "#1a1aff",//color of the pin when map load
"overColor": "#66d9ff",//color of the pin when mouse hover
"url": "#",//link to any webpage
"target": "none",// use "new_window", "same_window", "modal", or "none"
"active": true//true/false to activate/deactivate this pin
}
, {
"shape": "circle",//either "circle" or "square"
"hover": "GCF CO Abidjan
Abidjan, Cote d'Ivoire
",//info of the popup
"pos_X": 470,//check the X, Y coordinates guide in the documentation
"pos_Y": 440,
"size": 18,//size of the pin
"outline": "#000080",//outline color of the pin
"upColor": "#1a1aff",//color of the pin when map load
"overColor": "#66d9ff",//color of the pin when mouse hover
"url": "#",//link to any webpage
"target": "none",// use "new_window", "same_window", "modal", or "none"
"active": true//true/false to activate/deactivate this pin
}
, {
"shape": "circle",//either "circle" or "square"
"hover": "El Vekil lojistics
Istanbul, Turkey
",//info of the popup
"pos_X": 550,//check the X, Y coordinates guide in the documentation
"pos_Y": 330,
"size": 18,//size of the pin
"outline": "#000000",//outline color of the pin
"upColor": "#3700ff",//color of the pin when map load
"overColor": "#031de2",//color of the pin when mouse hover
"url": "#",//link to any webpage
"target": "none",// use "new_window", "same_window", "modal", or "none"
"active": true//true/false to activate/deactivate this pin
}
, {
"shape": "square",//either "circle" or "square"
"hover": "Ocean Crown Logistics
Antwerp, Belgium
",//info of the popup
"pos_X": 480,//check the X, Y coordinates guide in the documentation
"pos_Y": 290,
"size": 18,//size of the pin
"outline": "#000000",//outline color of the pin
"upColor": "#006eff",//color of the pin when map load
"overColor": "#006eff",//color of the pin when mouse hover
"url": "#",//link to any webpage
"target": "none",// use "new_window", "same_window", "modal", or "none"
"active": true//true/false to activate/deactivate this pin
}
, {
"shape": "square",//either "circle" or "square"
"hover": "CrossTrans Services International Freight
Hamburg, Germany
",//info of the popup
"pos_X": 495,//check the X, Y coordinates guide in the documentation
"pos_Y": 280,
"size": 18,//size of the pin
"outline": "#000000",//outline color of the pin
"upColor": "#006eff",//color of the pin when map load
"overColor": "#006eff",//color of the pin when mouse hover
"url": "#",//link to any webpage
"target": "none",// use "new_window", "same_window", "modal", or "none"
"active": true//true/false to activate/deactivate this pin
}
, {
"shape": "square",//either "circle" or "square"
"hover": "Global Cargo System
Valencia, Spain
",//info of the popup
"pos_X": 470,//check the X, Y coordinates guide in the documentation
"pos_Y": 345,
"size": 18,//size of the pin
"outline": "#000000",//outline color of the pin
"upColor": "#006eff",//color of the pin when map load
"overColor": "#006eff",//color of the pin when mouse hover
"url": "#",//link to any webpage
"target": "none",// use "new_window", "same_window", "modal", or "none"
"active": true//true/false to activate/deactivate this pin
}
, {
"shape": "square",//either "circle" or "square"
"hover": "Bansard International
Marseille, France
",//info of the popup
"pos_X": 480,//check the X, Y coordinates guide in the documentation
"pos_Y": 323,
"size": 18,//size of the pin
"outline": "#000000",//outline color of the pin
"upColor": "#006eff",//color of the pin when map load
"overColor": "#006eff",//color of the pin when mouse hover
"url": "#",//link to any webpage
"target": "none",// use "new_window", "same_window", "modal", or "none"
"active": true//true/false to activate/deactivate this pin
}
, {
"shape": "square",//either "circle" or "square"
"hover": "Tuscor lloyds
Manchester, United Kingdom
",//info of the popup
"pos_X": 460,//check the X, Y coordinates guide in the documentation
"pos_Y": 280,
"size": 18,//size of the pin
"outline": "#000000",//outline color of the pin
"upColor": "#006eff",//color of the pin when map load
"overColor": "#006eff",//color of the pin when mouse hover
"url": "#",//link to any webpage
"target": "none",// use "new_window", "same_window", "modal", or "none"
"active": true//true/false to activate/deactivate this pin
}
, {
"shape": "square",//either "circle" or "square"
"hover": "MESCO INTERNATIONAL FORWARDING INC.
Izmir, Turkey
",//info of the popup
"pos_X": 550,//check the X, Y coordinates guide in the documentation
"pos_Y": 340,
"size": 18,//size of the pin
"outline": "#000000",//outline color of the pin
"upColor": "#006eff",//color of the pin when map load
"overColor": "#006eff",//color of the pin when mouse hover
"url": "#",//link to any webpage
"target": "none",// use "new_window", "same_window", "modal", or "none"
"active": true//true/false to activate/deactivate this pin
}
, {
"shape": "square",//either "circle" or "square"
"hover": "TOP EXPERT DCE
Bucharest, Romania
",//info of the popup
"pos_X": 540,//check the X, Y coordinates guide in the documentation
"pos_Y": 320,
"size": 18,//size of the pin
"outline": "#000000",//outline color of the pin
"upColor": "#006eff",//color of the pin when map load
"overColor": "#006eff",//color of the pin when mouse hover
"url": "#",//link to any webpage
"target": "none",// use "new_window", "same_window", "modal", or "none"
"active": true//true/false to activate/deactivate this pin
}
, {
"shape": "square",//either "circle" or "square"
"hover": "CCS Srl
Asti, Italy
",//info of the popup
"pos_X": 490,//check the X, Y coordinates guide in the documentation
"pos_Y": 320,
"size": 18,//size of the pin
"outline": "#000000",//outline color of the pin
"upColor": "#046eff",//color of the pin when map load
"overColor": "#006eff",//color of the pin when mouse hover
"url": "#",//link to any webpage
"target": "none",// use "new_window", "same_window", "modal", or "none"
"active": true//true/false to activate/deactivate this pin
}
, {
"shape": "square",//either "circle" or "square"
"hover": "MAENTIVA Cargo
Prague, Czech Republic
",//info of the popup
"pos_X": 500,//check the X, Y coordinates guide in the documentation
"pos_Y": 300,
"size": 18,//size of the pin
"outline": "#000000",//outline color of the pin
"upColor": "#046eff",//color of the pin when map load
"overColor": "#006eff",//color of the pin when mouse hover
"url": "#",//link to any webpage
"target": "none",// use "new_window", "same_window", "modal", or "none"
"active": true//true/false to activate/deactivate this pin
}
, {
"shape": "square",//either "circle" or "square"
"hover": "United Win Logistics
Shanghai, China
",//info of the popup
"pos_X": 800,//check the X, Y coordinates guide in the documentation
"pos_Y": 370,
"size": 18,//size of the pin
"outline": "#000000",//outline color of the pin
"upColor": "#006eff",//color of the pin when map load
"overColor": "#046eff",//color of the pin when mouse hover
"url": "#",//link to any webpage
"target": "none",// use "new_window", "same_window", "modal", or "none"
"active": true//true/false to activate/deactivate this pin
}
, {
"shape": "square",//either "circle" or "square"
"hover": "REAL Access International, PT.
Jakarta, Indonesia
",//info of the popup
"pos_X": 760,//check the X, Y coordinates guide in the documentation
"pos_Y": 470,
"size": 18,//size of the pin
"outline": "#000000",//outline color of the pin
"upColor": "#006efb",//color of the pin when map load
"overColor": "#006eff",//color of the pin when mouse hover
"url": "#",//link to any webpage
"target": "none",// use "new_window", "same_window", "modal", or "none"
"active": true//true/false to activate/deactivate this pin
}
, {
"shape": "square",//either "circle" or "square"
"hover": "Dolphin Logistics Co., Ltd.
Taipei, Taiwan
",//info of the popup
"pos_X": 800,//check the X, Y coordinates guide in the documentation
"pos_Y": 405,
"size": 18,//size of the pin
"outline": "#000000",//outline color of the pin
"upColor": "#006eff",//color of the pin when map load
"overColor": "#006eff",//color of the pin when mouse hover
"url": "#",//link to any webpage
"target": "none",// use "new_window", "same_window", "modal", or "none"
"active": true//true/false to activate/deactivate this pin
}
, {
"shape": "square",//either "circle" or "square"
"hover": "ASIAAN TIGER LINES INDIA PRIVATE LIMITED
Chennai, India
",//info of the popup
"pos_X": 690,//check the X, Y coordinates guide in the documentation
"pos_Y": 420,
"size": 18,//size of the pin
"outline": "#000000",//outline color of the pin
"upColor": "#006efa",//color of the pin when map load
"overColor": "#006eff",//color of the pin when mouse hover
"url": "#",//link to any webpage
"target": "none",// use "new_window", "same_window", "modal", or "none"
"active": true//true/false to activate/deactivate this pin
}
, {
"shape": "square",//either "circle" or "square"
"hover": "Atlas Line Co. , Ltd.
Bangkok, Thailand
",//info of the popup
"pos_X": 750,//check the X, Y coordinates guide in the documentation
"pos_Y": 420,
"size": 18,//size of the pin
"outline": "#000000",//outline color of the pin
"upColor": "#006eff",//color of the pin when map load
"overColor": "#006eff",//color of the pin when mouse hover
"url": "#",//link to any webpage
"target": "none",// use "new_window", "same_window", "modal", or "none"
"active": true//true/false to activate/deactivate this pin
}
, {
"shape": "square",//either "circle" or "square"
"hover": "Paklink Shipping Services
Karachi, Pakistan
",//info of the popup
"pos_X": 660,//check the X, Y coordinates guide in the documentation
"pos_Y": 390,
"size": 18,//size of the pin
"outline": "#000000",//outline color of the pin
"upColor": "#006eff",//color of the pin when map load
"overColor": "#006eff",//color of the pin when mouse hover
"url": "#",//link to any webpage
"target": "none",// use "new_window", "same_window", "modal", or "none"
"active": true//true/false to activate/deactivate this pin
}
, {
"shape": "square",//either "circle" or "square"
"hover": "INTERUNION FREIGHT SDN BHD
Kuala Lumpur, Malaysia
",//info of the popup
"pos_X": 750,//check the X, Y coordinates guide in the documentation
"pos_Y": 440,
"size": 18,//size of the pin
"outline": "#000000",//outline color of the pin
"upColor": "#046eff",//color of the pin when map load
"overColor": "#006eff",//color of the pin when mouse hover
"url": "#",//link to any webpage
"target": "none",// use "new_window", "same_window", "modal", or "none"
"active": true//true/false to activate/deactivate this pin
}
, {
"shape": "square",//either "circle" or "square"
"hover": "AIR 7 SEAS Transport Logistics Inc
San Jose, USA
",//info of the popup
"pos_X": 160,//check the X, Y coordinates guide in the documentation
"pos_Y": 370,
"size": 18,//size of the pin
"outline": "#000000",//outline color of the pin
"upColor": "#006eff",//color of the pin when map load
"overColor": "#006eff",//color of the pin when mouse hover
"url": "#",//link to any webpage
"target": "none",// use "new_window", "same_window", "modal", or "none"
"active": true//true/false to activate/deactivate this pin
}
, {
"shape": "square",//either "circle" or "square"
"hover": "Link Lines Logistics, Inc.
New Jersey, USA
",//info of the popup
"pos_X": 280,//check the X, Y coordinates guide in the documentation
"pos_Y": 320,
"size": 18,//size of the pin
"outline": "#000000",//outline color of the pin
"upColor": "#006eff",//color of the pin when map load
"overColor": "#006eff",//color of the pin when mouse hover
"url": "#",//link to any webpage
"target": "none",// use "new_window", "same_window", "modal", or "none"
"active": true//true/false to activate/deactivate this pin
}
, {
"shape": "square",//either "circle" or "square"
"hover": "Carolina logistics mexico
South Carolina, USA
",//info of the popup
"pos_X": 250,//check the X, Y coordinates guide in the documentation
"pos_Y": 350,
"size": 18,//size of the pin
"outline": "#000000",//outline color of the pin
"upColor": "#006eff",//color of the pin when map load
"overColor": "#006eff",//color of the pin when mouse hover
"url": "#",//link to any webpage
"target": "none",// use "new_window", "same_window", "modal", or "none"
"active": true//true/false to activate/deactivate this pin
}
, {
"shape": "square",//either "circle" or "square"
"hover": "Grupo JM Logística
Niterói, Brazil
",//info of the popup
"pos_X": 340,//check the X, Y coordinates guide in the documentation
"pos_Y": 520,
"size": 18,//size of the pin
"outline": "#000000",//outline color of the pin
"upColor": "#006eff",//color of the pin when map load
"overColor": "#006eff",//color of the pin when mouse hover
"url": "#",//link to any webpage
"target": "none",// use "new_window", "same_window", "modal", or "none"
"active": true//true/false to activate/deactivate this pin
}
, {
"shape": "square",//either "circle" or "square"
"hover": "Target logistics Qatar W.L.L
Doha, Qatar
",//info of the popup
"pos_X": 660,//check the X, Y coordinates guide in the documentation
"pos_Y": 380,
"size": 18,//size of the pin
"outline": "#000000",//outline color of the pin
"upColor": "#006eff",//color of the pin when map load
"overColor": "#006eff",//color of the pin when mouse hover
"url": "#",//link to any webpage
"target": "none",// use "new_window", "same_window", "modal", or "none"
"active": true//true/false to activate/deactivate this pin
}
, {
"shape": "square",//either "circle" or "square"
"hover": "Direct Shipping Services LLC
Dubai, UAE
",//info of the popup
"pos_X": 620,//check the X, Y coordinates guide in the documentation
"pos_Y": 385,
"size": 18,//size of the pin
"outline": "#000000",//outline color of the pin
"upColor": "#006eff",//color of the pin when map load
"overColor": "#006eff",//color of the pin when mouse hover
"url": "#",//link to any webpage
"target": "none",// use "new_window", "same_window", "modal", or "none"
"active": true//true/false to activate/deactivate this pin
}
, {
"shape": "square",//either "circle" or "square"
"hover": "Al Awan Al Motamize Corporation
Riyadh, Saudi Arabia
",//info of the popup
"pos_X": 600,//check the X, Y coordinates guide in the documentation
"pos_Y": 390,
"size": 18,//size of the pin
"outline": "#000000",//outline color of the pin
"upColor": "#006eff",//color of the pin when map load
"overColor": "#006eff",//color of the pin when mouse hover
"url": "#",//link to any webpage
"target": "none",// use "new_window", "same_window", "modal", or "none"
"active": true//true/false to activate/deactivate this pin
}
, {
"shape": "square",//either "circle" or "square"
"hover": "Compass ocean logistics
Muscat, Sultanate of Oman
",//info of the popup
"pos_X": 630,//check the X, Y coordinates guide in the documentation
"pos_Y": 385,
"size": 18,//size of the pin
"outline": "#000000",//outline color of the pin
"upColor": "#006eff",//color of the pin when map load
"overColor": "#006eff",//color of the pin when mouse hover
"url": "#",//link to any webpage
"target": "none",// use "new_window", "same_window", "modal", or "none"
"active": true//true/false to activate/deactivate this pin
}
, {
"shape": "square",//either "circle" or "square"
"hover": "Al Maasar Al Iraqi Co. - LLC
Basrah, Iraq
",//info of the popup
"pos_X": 600,//check the X, Y coordinates guide in the documentation
"pos_Y": 370,
"size": 18,//size of the pin
"outline": "#000000",//outline color of the pin
"upColor": "#006eff",//color of the pin when map load
"overColor": "#006eff",//color of the pin when mouse hover
"url": "#",//link to any webpage
"target": "none",// use "new_window", "same_window", "modal", or "none"
"active": true//true/false to activate/deactivate this pin
}
, {
"shape": "square",//either "circle" or "square"
"hover": "Elaf Cargo Group
Amman, Jordan
",//info of the popup
"pos_X": 570,//check the X, Y coordinates guide in the documentation
"pos_Y": 370,
"size": 18,//size of the pin
"outline": "#000000",//outline color of the pin
"upColor": "#006eff",//color of the pin when map load
"overColor": "#006eff",//color of the pin when mouse hover
"url": "#",//link to any webpage
"target": "none",// use "new_window", "same_window", "modal", or "none"
"active": true//true/false to activate/deactivate this pin
}
]
};
// The following is the script for pins interaction DON'T EDIT !!!
function isTouchEnabled() {
return (("ontouchstart" in window)
|| (navigator.MaxTouchPoints > 0)
|| (navigator.msMaxTouchPoints > 0));
}
jQuery(function () {
var pins_len = pins_config.pins.length;
if(pins_len > 0) {
var xmlns = "http://www.w3.org/2000/svg";
var tsvg_obj = document.getElementById("wdctjspins");
var svg_circle, svg_rect;
for (var i = 0; i < pins_len; i++) {
if (pins_config.pins[i].shape === "circle") {
svg_circle = document.createElementNS(xmlns, "circle");
svg_circle.setAttributeNS(null, "cx", pins_config.pins[i].pos_X + 1);
svg_circle.setAttributeNS(null, "cy", pins_config.pins[i].pos_Y + 1);
svg_circle.setAttributeNS(null, "r", pins_config.pins[i].size / 2);
svg_circle.setAttributeNS(null, "fill", "rgba(0, 0, 0, 0.5)");
tsvg_obj.appendChild(svg_circle);
svg_circle = document.createElementNS(xmlns, "circle");
svg_circle.setAttributeNS(null, "cx", pins_config.pins[i].pos_X);
svg_circle.setAttributeNS(null, "cy", pins_config.pins[i].pos_Y);
svg_circle.setAttributeNS(null, "r", pins_config.pins[i].size / 2);
svg_circle.setAttributeNS(null, "fill", pins_config.pins[i].upColor);
svg_circle.setAttributeNS(null, "stroke", pins_config.pins[i].outline);
svg_circle.setAttributeNS(null, "stroke-width", 1);
svg_circle.setAttributeNS(null, "id", "wdctjspins_" + i);
tsvg_obj.appendChild(svg_circle);
wdctjsAddEvent(i);
}
else if (pins_config.pins[i].shape === "square") {
svg_rect = document.createElementNS(xmlns, "rect");
svg_rect.setAttributeNS(null, "x", pins_config.pins[i].pos_X - pins_config.pins[i].size / 2 + 1);
svg_rect.setAttributeNS(null, "y", pins_config.pins[i].pos_Y - pins_config.pins[i].size / 2 + 1);
svg_rect.setAttributeNS(null, "width", pins_config.pins[i].size);
svg_rect.setAttributeNS(null, "height", pins_config.pins[i].size);
svg_rect.setAttributeNS(null, "fill", "rgba(0, 0, 0, 0.5)");
tsvg_obj.appendChild(svg_rect);
svg_rect = document.createElementNS(xmlns, "rect");
svg_rect.setAttributeNS(null, "x", pins_config.pins[i].pos_X - pins_config.pins[i].size / 2);
svg_rect.setAttributeNS(null, "y", pins_config.pins[i].pos_Y - pins_config.pins[i].size / 2);
svg_rect.setAttributeNS(null, "width", pins_config.pins[i].size);
svg_rect.setAttributeNS(null, "height", pins_config.pins[i].size);
svg_rect.setAttributeNS(null, "fill", pins_config.pins[i].upColor);
svg_rect.setAttributeNS(null, "stroke", pins_config.pins[i].outline);
svg_rect.setAttributeNS(null, "stroke-width", 1);
svg_rect.setAttributeNS(null, "id", "wdctjspins_" + i);
tsvg_obj.appendChild(svg_rect);
wdctjsAddEvent(i);
}
}
}
});
function wdctjsAddEvent(id) {
var obj = jQuery("#wdctjspins_" + id);
if(pins_config.pins[id].active === true){
obj.attr({"cursor": "pointer"});
obj.hover(function () {
jQuery("#wdctjstip").show().html(pins_config.pins[id].hover);
obj.css({"fill":pins_config.pins[id].overColor});
}, function () {
jQuery("#wdctjstip").hide();
obj.css({"fill":pins_config.pins[id].upColor});
});
obj.mouseup(function(){
obj.css({"fill":pins_config.pins[id].overColor});
if (pins_config.pins[id].target === "new_window"){
window.open(pins_config.pins[id].url);
} else if (pins_config.pins[id].target === "same_window") {
window.parent.location.href = pins_config.pins[id].url;
} else if (pins_config.pins[id].target === "modal") {
jQuery(pins_config.pins[id].url).modal("show");
}
});
obj.mousemove(function (e) {
var x = e.pageX + 10, y = e.pageY + 15;
var tipw =jQuery("#wdctjstip").outerWidth(), tiph =jQuery("#wdctjstip").outerHeight(),
x = (x + tipw >jQuery(document).scrollLeft() +jQuery(window).width())? x - tipw - (20 * 2) : x ;
y = (y + tiph >jQuery(document).scrollTop() +jQuery(window).height())? jQuery(document).scrollTop() +jQuery(window).height() - tiph - 10 : y ;
jQuery("#wdctjstip").css({left: x, top: y});
});
if (isTouchEnabled()) {
obj.on("touchstart", function (e) {
var touch = e.originalEvent.touches[0];
var x = touch.pageX + 10, y = touch.pageY + 15;
var tipw=jQuery("#wdctjstip").outerWidth(), tiph=jQuery("#wdctjstip").outerHeight(),
x = (x + tipw >jQuery(document).scrollLeft() +jQuery(window).width())? x - tipw -(20 * 2) : x ;
y =(y + tiph >jQuery(document).scrollTop() +jQuery(window).height())? jQuery(document).scrollTop() +jQuery(window).height() -tiph - 10 : y ;
jQuery("#wdctjstip").show().html(pins_config.pins[id].hover);
jQuery("#wdctjstip").css({left:x, top:y});
});
obj.on("touchend", function () {
jQuery("#" + id).css({"fill":pins_config.pins[id].upColor});
if (pins_config.pins[id].target === "new_window") {
window.open(pins_config.pins[id].url);
} else if (pins_config.pins[id].target === "same_window") {
window.parent.location.href = pins_config.pins[id].url;
} else if (pins_config.pins[id].target === "modal") {
jQuery(pins_config.pins[id].url).modal("show");
}
});
}
}
}