[Xapian-discuss] Pretty URLs for omega?

xapian at catcons.co.uk xapian at catcons.co.uk
Sat Apr 9 07:55:06 BST 2011


Hello :-)

How can the default omega URL be prettified?

http://<host_ID>/cgi-bin/omega is working fine, giving us all omega's
default CGI parameters.  Now we want multiple databases which could be
accessed using http://<host_ID>/cgi-bin/omega?DB=<index_ID> but this is
starting to get messy.  It will get messier when we start to customise
templates with &FMT=<template_ID> (?) and so on.

It would be nice if the users had a simple, memorable URL such as
http://<host_ID>/search which we could use to generate customised omega CGI
URLs.

The nearest solution I found was this index.html but it did not display the
number of documents in the index as http://<host_ID>/cgi-bin/omega does:

<head>
<title>Intranet Search</title>
</head>
<body bgcolor="#ffffff">
<FORM NAME=P METHOD=GET
ACTION="/cgi-bin/omega" TARGET="_top">
<center>
<INPUT NAME=P VALUE="" SIZE=65>
<INPUT TYPE=SUBMIT VALUE="Search">
<hr>
<INPUT TYPE=radio NAME=DEFAULTOP VALUE=or > Match any word
<INPUT TYPE=radio NAME=DEFAULTOP VALUE=and CHECKED> Match all words
</center><br>
<INPUT TYPE=hidden NAME=DB VALUE="default">
<INPUT TYPE=hidden NAME=FMT VALUE="query">
<INPUT TYPE=hidden NAME=xDB VALUE="default">
<INPUT TYPE=hidden NAME=xFILTERS VALUE="--O">
</FORM>
<hr>
</body>
</html>

Source of above index.html:
http://viktorpetersson.com/2010/08/01/create-a-lightweight-intranet-search-e
ngine-with-xapian-on-freebsd/  

Sorry if this question is naïve; I'm a sysadmin not a web programmer.    
 
Best

Charles




More information about the Xapian-discuss mailing list