[Qgis-developer] QWC wsgi search
Marc Beiling
beiling at gbd-consult.de
Fri Jun 19 00:50:59 PDT 2015
Hi Bernhard, Andreas,
thank you!
It has been a problem with the credentials (again for me).
It is working now.
I'm working on the configuration of the search to fit my needs now.
Might be, that I'll be back here to ask you for help again. But I
try to figure it out on my own first of course.
Have a nice weekend,
Marc
Am Tue, 16 Jun 2015 07:51:16 +0200
schrieb Bernhard Ströbl <bernhard.stroebl at jena.de>:
> Hi Marc,
>
> in addition to what Andreas wrote: You should see in Apache's log
> file if something goes wrong with the database connection. Things
> that may go wrong in this respect are:
> 1) connection to the server is not allowed from the machine the wsgi
> script is located on with the method used (normally username +
> password); file pg_hba_conf
> 2) the user may connect to the server but not to the database in
> question 3) the user has no SELECT rights on one of the searchtables
>
> You must have mod_wsgi installed and configured on your Apache
> server, of course.
>
> To easily debug the wsgi-search you may want to enter the search URL
> directly in your browser like
> http://my-page.de/wsgi/search.wsgi?query=wo&searchtables=&cb=stcCallback1001
>
> once you get an answer there you can try it from within QWC
>
> Bernhard
>
> Am 15.06.2015 um 20:33 schrieb Andreas Neumann:
> > Hi Marc,
> >
> > Here is a wsgi search query from our server:
> >
> > http://webgis.uster.ch/wsgi/search.wsgi?searchtables=&query=Werriker&cb=stcCallback1005
> >
> >
> > Note that there are builtin searchtables that are always used
> > (things like addresses, parcel numbers, building assurance numbers,
> > geographic names, etc.) - you can add additional searchtables e.g.
> > for waste-water pipes, etc.
> >
> > The double query parameter is a mistake and stems from the fact
> > that it is by mistake also specified in GlobalOptions.js - look for
> > a line with
> >
> > Konsole output
> > varsearchBoxQueryURL = "/wsgi/search.wsgi?";
> >
> > and remove the extra query parameter. But it is not a big deal, the
> > second parameter just replaces the empty one.
> >
> > Other than that you must check the database permissions and if the
> > login parameters are correct.
> >
> > In the file "search.js" you have to add the default searchtables
> > array, if you did not specify one in the URL - something like:
> >
> > Konsole output
> > searchtables =
> > ['surveydata.searchtable_addresses','gisdata.searchtable_geographicnames'];
> >
> > So please double check that your searchtables can be accessed with
> > the permissions of the web server user, if the login data is
> > correct and if the searchtables are specified and contain a valid
> > structure.
> >
> > Hope this helps,
> > Andreas
> >
> > On 15.06.2015 17:46, Marc B wrote:
> >> Hello List,
> >>
> >> I am trying to connect the WSGI-Search to my PostGIS-Database.
> >> Unfortunately I am reatively new to python and I dont really
> >> understand which changes in the search.wsgi/qwc_connect.py I have
> >> to make.
> >>
> >> I've created a DB-table like the one from the github instructions.
> >> I've changed the DB_CONN_STRING in qwc_connect.py.
> >>
> >> Some of my Questions are
> >>
> >> 1. Is there a way to easily test my DB-Connection in qwc_connect?
> >> 2. The generated URL with parameters is not how ist supposed to be:
> >>
> >> https://my-page.de/wsgi/search.wsgi?query=&searchtables=&query=wo&cb=stcCallback1001
> >>
> >>
> >> - Why are there 2 'query'-params, an empty and a correct one?
> >> - the searchtables-parameter has no value, whether I put in a
> >> tablename in the search.wsgi or not ( searchtables =
> >> ['searchtable']; # enter your default searchtable(s) here ).
> >> Where does this parameter come from? What am i doing wrong?
> >>
> >> If I paste the url in the url bar of chrome it says "error: no
> >> search table". When I put a searchtable-value in the url i get a
> >> blank page. It never says 'error: could not execute query'. So I
> >> guess, it doesnt even get that far.
> >>
> >> Thank you
> >> Marc
> >> _______________________________________________
> >> Qgis-developer mailing list
> >> Qgis-developer at lists.osgeo.org
> >> http://lists.osgeo.org/mailman/listinfo/qgis-developer
> >
> >
> >
> >
> > __________ Information from ESET Mail Security, version of virus
> > signature database 11790 (20150615) __________
> >
> > The message was checked by ESET Mail Security.
> > http://www.eset.com
> >
> >
> >
> >
> > _______________________________________________
> > Qgis-developer mailing list
> > Qgis-developer at lists.osgeo.org
> > http://lists.osgeo.org/mailman/listinfo/qgis-developer
> >
> >
> > __________ Information from ESET Mail Security, version of virus
> > signature database 11790 (20150615) __________
> >
> > The message was checked by ESET Mail Security.
> > http://www.eset.com
> >
>
--
Geoinformatikbüro Dassau GmbH
Rethelstrasse 153
D - 40237 Düsseldorf
Tel: +49-211-69937750
Fax: +49-211-69937751
Mobile: +49-171-4687540
http://www.gbd-consult.de
Registergericht: Amtsgericht Düsseldorf, HR B 74022
Geschäftsführer: Otto Dassau
More information about the Qgis-developer
mailing list