Skip to content

Commit

Permalink
Merge pull request #9125 from m-kuhn/backport-wmts-getcapabilities-co…
Browse files Browse the repository at this point in the history
…mpat

Append ? to WMTS GetCapabilities
  • Loading branch information
m-kuhn committed Feb 8, 2019
2 parents 3699529 + a140a4a commit e6b8523
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions src/server/services/wmts/qgswmtsgetcapabilities.cpp
Expand Up @@ -278,8 +278,12 @@ namespace QgsWmts
QDomElement httpElement = doc.createElement( QStringLiteral( "ows:HTTP" )/*ows:HTTP*/ );
dcpElement.appendChild( httpElement );

//Prepare url
QString hrefString = serviceUrl( request, project );
// Get service URL
const QUrl href = serviceUrl( request, project );

//href needs to be a prefix
QString hrefString = href.toString();
hrefString.append( href.hasQuery() ? '&' : '?' );

//ows:Get
QDomElement getElement = doc.createElement( QStringLiteral( "ows:Get" )/*ows:Get*/ );
Expand Down

0 comments on commit e6b8523

Please sign in to comment.