Link to home
Start Free TrialLog in
Avatar of Neil_Bradley
Neil_BradleyFlag for New Zealand

asked on

test for ie in jquery

I am using a custom icon for a Google map marker. Problem is that ie<9 does not support my custom marker so I would like to conditionally add "icon:$icon" into my script.

Essentially I would like to:

var marker1 = new google.maps.Marker({

// is IE version less than 9 add this
                  icon: $icon,
// else do nothing
                  position: new google.maps.LatLng(-45.03145, 168.660030),
                  map: map,
                  title: "Some Title"


Cheers,
N
ASKER CERTIFIED SOLUTION
Avatar of Gary
Gary
Flag of Ireland image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of Neil_Bradley

ASKER

Great work! The solutions worked very well.
Pity I had to roll back my version of jquery to make this work as ts a really hand tool!
N
Pity I had to roll back my version of jquery to make this work as ts a really hand tool!

Was not the right thing to do...