We set up a QGIS server and are using QGIS to connect to a WFS layer. Everything is working fine within the desktop application. Then we use qgis2leaf to generate a html/js web map. That all works fine, except when I use the WFS layer. For some reason I am getting the Unexpected token < error, as can be seen here (http://qgis.webmuni.com/export).
So basically what I think is happening is that the call that is made is (http://qgis.webmuni.com/qgis_mapserv.fcgi?SERVICE=WFS&VERSION=1.0.0&REQUEST=GetFeature&TYPENAME=zones2&SRSNAME=EPSG:4326&outputFormat=text/javascript&format_options=callback:processJSON) and it expects it to return JSON, but the server is returning XML.
I don't know why the server wont return JSON(P) and I am not sure if there is something I am doing wrong or if we need to configure the server in some way to enable JSON capabilities.