|
|
|||||||||
|
|||||||||
| |||||||||
|
|
|
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
|
|
Get inside! Sample the range of functionality easily built with JMSL Library for Time Series Data Analysis, Heat Maps, Portfolio Optimization, Monte Carlo Simulation, Stock Price Charting and more. Download Now! |
|
#1
|
|||
|
|||
|
I am searching for a way to look at generated files in Apache before they are transmitted to the client. The files can be generated by any dynamic page (PHP, CGI, JSP, etc.). Can this be done at all? Can this be done using an Apache Module?
|
|
#2
|
|||
|
|||
|
>>Can this be done at all? Can this be done using an Apache Module?
Don't understand at all. Why can't you view your own files before launching your site? If you want to look at the generated files, then you are already the client. If you want to intercept the file, you are still the unique client. Start here to search for a particular module of Apache -> http://modules.apache.org/ |
|
#3
|
|||
|
|||
|
Thanks for your reply. Let me further explain: I want to programmatically add extra post-processing to requests before they are sent out to clients (For instance, adding additional or changing HTML code), and to do that for all types of requests (cgi, php, etc). I do not want to do so as a proxy or a client, but from within the Apache server itself. The only solution I could find was Servlet Chaining, which isn't supported by Apache JServ.
<BLOCKQUOTE><font size="1" face="Verdana,Arial,Helvetica">quote:</font><HR>Originally posted by freebsd: >>Can this be done at all? Can this be done using an Apache Module? Don't understand at all. Why can't you view your own files before launching your site? If you want to look at the generated files, then you are already the client. If you want to intercept the file, you are still the unique client. Start here to search for a particular module of Apache -> http://modules.apache.org/ [/quote] |
|
#4
|
|||
|
|||
|
>>I want to programmatically add extra post-processing to requests before they are
sent out to clients This example would get the client's http referer and determine what output to send. #!/usr/local/bin/perl $referer = "$ENV{'HTTP_REFERER'}"; print "Content-type: text/htmlnn"; print "<html>n<body>n"; if ($referer) { print "It appears you are coming from "; print "$referern"; } else { print "Hello Worldn"; } print "</body>n</html>n"; Or within an html document, or PHP, you can use "include". Anyway, you should put whatever codes within your script to do whatever post-processing tasks. If you are talking about Apache, you can put something like this in your .htaccess file: RedirectMatch index.html http://foo.bar.com/file.jsp [This message has been edited by freebsd (edited August 07, 2000).] |
![]() |
| Viewing: Dev Shed Forums > System Administration > Apache Development > Chaining Apache Modules |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|