0
votes

I am new in MapBox IOS sdk and i have no idea,how to load custom Map in MapBox. Here my Custom Map:

https://api.tiles.mapbox.com/v4/faridullah.loj1n5f3/page.html?access_token=pk.eyJ1IjoiZmFyaWR1bGxhaCIsImEiOiJVU3ZCNS1VIn0.Owqu7VB5OZQbGj3LBBpPOA#16/33.6471/72.9881

and my code:

#define kMapboxMapID @"faridullah.loj1n5f3"

- (void)viewDidLoad {

    [super viewDidLoad];

RMMapboxSource *onlineSource = [[RMMapboxSource alloc] initWithMapID:kMapboxMapID];

RMMapView *mapView = [[RMMapView alloc] initWithFrame:self.view.bounds andTilesource:onlineSource];

    mapView.zoom = 5;
    mapView.delegate = self;
    mapView.autoresizingMask = UIViewAutoresizingFlexibleHeight | UIViewAutoresizingFlexibleWidth;

    [self.view addSubview:mapView];
    mapView.showsUserLocation=YES;

}

but the markers doesnot display on device...

1
What is your issue exactly? The documentation has very good example codejalone
@jalone my issue is that ,the markers doesnot display on device..Farid

1 Answers

0
votes

Just follow this example and implement the needed or delegate methods

https://www.mapbox.com/mapbox-ios-sdk/examples/marker-custom-image/