Skip to content

WMS layer always appends ? even if WMS server address already contains query string params #973

@StupidTook

Description

@StupidTook

We are using in-house developed WMS server that takes additional params that are not part of WMS protocol.

It looks like this:

var layer = L.tileLayer.wms("http://example.com/Wms.aspx?map=1", {
    layers: 'buildings',
    format: 'image/png',
    transparent: false    
});

The problem is, leaflet appends WMS params with ? prefix regardless of whether the url already has params or not, so what we get is:

http://example.com/Wms.aspx?map=1?service=WMS&request=GetMap

It would be really nice if leaflet could append its params using ampersand if the service address already includes a query string.

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions