Le lundi 28 novembre 2011 à 23:26 +0100, André Warnier a écrit : > you may want to try > > <VirtualHost */*> > ServerName "as-pro.biz" > .. > </VirtualHost> > <VirtualHost */*> > ServerName "customer1.biz" > .. > </VirtualHost>
> That is much more flexible (and a lot less work in the long term) than > adapting your > software each time a customer wants something different. > I use this : <Location /clients> PerlHeaderParserHandler Aspro::Clients::HeaderParser::get_session_id PerlOutputFilterHandler Aspro::Clients::Filter::html_head_and_tail </Location> and then (for instance) : <Location /clients/agents> SetHandler perl-script PerlResponseHandler Aspro::Clients::Agents::agents </location> The headerparser uses the cookie to retrieve the session data from a PostgreSQL database; it places that data inside pnotes(), including client id. The perlresponsehandler generates the requested page, using pnotes for session data. The OutputFilter adds the proper html tags for css and logo around the content using client id in pnotes(). It stores the session data back into the postgresql database for the next query. I pasted the code here : http://pastebin.com/CCfLwHmi The system is quite fast for my needs, and reproduceable, which is nice. I can customize my pages almost at will, certainly a lot more than I do now, and keep only one set of modules. -- Vincent Veyron http://marica.fr/ Logiciel de gestion des sinistres et des contentieux pour le service juridique