Hi!
We try to integrate Jetspeed/Turbine in a more complex environment using a
gateway as a front-end machine. All HTTP requests are sent to the gateway
which routes them through a firewall to my Jetspeed/Turbine machine.
The code generated by Turbine is returned afterwards by the gateway to the
user's browser.
My problem is the fact that the URLs in the returned HTML code are absolute
addresses!
Thus, every browser tries to load its pages directly from the
Jetspeed/Turbine machine which is unreachable due to the firewall/gateway
construction.
The method toString() in org.apache.turbine.util.DynamicURI is used to
create the URIs from a given screen and action. Is it necessary that it
returns an absolute URI? I changed it as below in my system and everything
works fine.
There is also a second (static) toString method. This one is not even used
in the Turbine code, is it obsolete?
Apart from my problem, I think it is not a good style to include absolute
URLs in HTML tags unless it is required to do so.
Can anybody have a look at this problem?
--- C:\DynamicURI.java Thu Dec 07 09:12:24 2000
+++ C:\_DynamicURI.java Thu Dec 07 09:12:25 2000
@@ -962,16 +962,16 @@
public String toString()
{
StringBuffer output = new StringBuffer();
- output.append ( getServerScheme() );
- output.append ( "://" );
- output.append ( getServerName() );
- if ( (getServerScheme().equals(HTTP) && getServerPort() != 80)
- || (getServerScheme().equals(HTTPS) && getServerPort() != 443)
- )
- {
- output.append (":");
- output.append ( getServerPort() );
- }
+// output.append ( getServerScheme() );
+// output.append ( "://" );
+// output.append ( getServerName() );
+// if ( (getServerScheme().equals(HTTP) && getServerPort() != 80)
+// || (getServerScheme().equals(HTTPS) && getServerPort() !=
443)
+// )
+// {
+// output.append (":");
+// output.append ( getServerPort() );
+// }
output.append ( getScriptName() );
if ( this.hasPathInfo )
{
cya,
David
-----
public void mystery_of_life()
{
do
{
System.breatheIn();
System.breatheOut();
}
while( !dead );
}
------------------------------------------------------------
To subscribe: [EMAIL PROTECTED]
To unsubscribe: [EMAIL PROTECTED]
Search: <http://www.mail-archive.com/turbine%40list.working-dogs.com/>
Problems?: [EMAIL PROTECTED]