Yet, it does. I have Apache talk to Webkit (either OneShot or mod_webkit) via a Location directive, which specifies the workdir, as per the mod_webkit docstring. So, frontend is not on the path, yet SitePage (which sits in /frontend) is accessible by a browser. Which makes sense to me, since it's in the default WK context. I am just looking for a cleaner setup...
Thanks, Costas >From: "Aaron Held" <[EMAIL PROTECTED]> >To: "Costas Malamas" <[EMAIL PROTECTED]>, ><[EMAIL PROTECTED]> >Subject: Re: [Webware-discuss] Cleaning up AppWorkDir and better 404 >handling... >Date: Wed, 12 Dec 2001 10:01:11 -0500 > >1) the webware WorkDir should not be in the web path. >Only put the WebKit.cgi or OneShot.cgi in the cgi-bin . > >There should be no way for a browser to request a page directly. >So http://mymachine/webware_location/SitePage should be >http://mymachine/WebKit.cgi/frontend/ > >2) I agree w/ the basic error page, see line 373 of WebKit/Application.py >def handleBadURL(self, transaction): > res = transaction.response() > res.setHeader('Status', '404 Error') >## res.write('<p> 404 Not found: %s' % transaction.request().uri()) > res.write(self._404Page % (transaction.request().uri())) > # @@ 2000-06-26 ce: This error page is pretty primitive > # @@ 2000-06-26 ce: We should probably load a separate template file and >display that > >As a simple fix I use a 404.txt w/ a client side redirect. But that is >primative also because I lose any request parameters, but >thats not a big problem because I <i> never</i> type a link wrong. > >BTW Webware looks for the 404.txt in the working dir first and then uses >the one under WebKit. > >Thanks, >-Aaron > > >----- Original Message ----- >From: "Costas Malamas" <[EMAIL PROTECTED]> >To: <[EMAIL PROTECTED]> >Sent: Wednesday, December 12, 2001 2:40 PM >Subject: [Webware-discuss] Cleaning up AppWorkDir and better 404 >handling... > > > > Hi all, > > > > Coupla questions: > > > > I have a fairly largish python package for which WebWare acts as its > > frontend. Thus my package is structured like this: > > /package > > /sub-package1 > > /sub-package2 > > /frontend > > > > I put all the Webware-specific stuff under /frontend, incl. my SitePage, >and > > run the createAppWorkDir (?) script for /frontend. Everything worked >out of > > the box and that's cool, but now a browser can hit > > http://mymachine/webware_location/SitePage and get a page (a blank one, >but > > still a page). I know I am being ...er... detail-oriented, but I don't >like > > that. What's the best way to handle this? how do y'all usually setup > > installations? Should I put the WK classes under another sub-package >and > > import them instead? > > > > Secondly, I am kinda disappointed in the way WebKit handles 404s. A >simple > > text message isn't enough I think: I'd like to provide a search page or >a > > good guess at what the user was trying to get at. I could batch-create >a > > static 404 page and save it as 404text.txt, but that detail-orientation > > again :-)... Is it possible that Application.py tries to serve a 404Page > > (possibly set in Application.config) before defaulting to 404text.txt? >In > > the same vain, I'd like an error page caused by an exception to go to a >Page > > class if possible (I know this may not work if the exception is in >SitePage) > > instead of the default traceback page. > > > > I'd be happy to start hacking away and add these features, if someone >can > > gimme some starting hints (WK internals mostly go over my head still). > > > > Anyways, thanks in advance --just the fact that after weeks of working >on > > WK, I only find cosmetic stuff to nitpick on says something about >Webware > > :-)... > > > > C. > > > > > > > > _________________________________________________________________ > > Send and receive Hotmail on your mobile device: http://mobile.msn.com > > > > > > _______________________________________________ > > Webware-discuss mailing list > > [EMAIL PROTECTED] > > https://lists.sourceforge.net/lists/listinfo/webware-discuss > > > >_______________________________________________ >Webware-discuss mailing list >[EMAIL PROTECTED] >https://lists.sourceforge.net/lists/listinfo/webware-discuss _________________________________________________________________ Chat with friends online, try MSN Messenger: http://messenger.msn.com _______________________________________________ Webware-discuss mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/webware-discuss
