[qgis-qwc2] QWC2 Server examples

Sandro Mani manisandro at gmail.com
Thu Mar 23 05:35:45 PDT 2017



On 23.03.2017 06:15, DimK wrote:
> Hi, all
>
> I have a question about QWC2 Server. Are there some examles about?
>
> How can I set my QGIS Server reference 
> http://localhost/cgi-bin/qgis_mapserv.fcgi.exe?map=c:\path_to_qgis_project\helloworld.qgs 
> to reference like http://localhost/helloworld ?
>
Hi

If you use Apache, you can add a RewriteRule like

RewriteEngine on
RewriteRule ^/wms/(.+)$ 
/qgis/qgis_mapserv.fcgi?map=/path/to/projects/$1.qgs [QSA,PT]
ScriptAlias /qgis/ "/path/to/qgis/bin/"

Then http://localhost/wms/myproject is rewritten to 
/path/to/qgis/bin/qgis_mapserv.fcgi?map=/path/to/projects/myproject.qgs

Best
Sandro



More information about the qgis-qwc2 mailing list