Author: tyrell
Date: Thu May 22 00:33:29 2008
New Revision: 17245
Log:
Fixing MASHUP-658
Modified:
trunk/mashup/java/modules/www/mashup.jsp
Modified: trunk/mashup/java/modules/www/mashup.jsp
==============================================================================
--- trunk/mashup/java/modules/www/mashup.jsp (original)
+++ trunk/mashup/java/modules/www/mashup.jsp Thu May 22 00:33:29 2008
@@ -27,6 +27,8 @@
<%@ page import="org.wso2.registry.Tag" %>
<%@ page import="java.util.Iterator" %>
<%@ page import="java.util.ResourceBundle" %>
+<%@ page import="org.wso2.wsas.ServerManager" %>
+<%@ page import="java.net.URL" %>
<!--Required to keep a user logged in if 'Remember Me' option is selected-->
<%@ include file="validate_login.jsp" %>
@@ -60,6 +62,11 @@
response.sendRedirect("faulty_mashup.jsp?path=" + path);
}
+ // Creating an HTTP version of the current URL to be used when required
+ String httpUrl =
+ new URL("http", request.getServerName(),
ServerManager.getInstance().getHttpPort(), "").toString() + "/";
+
+
%><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html>
@@ -417,19 +424,19 @@
'View the <a href="services/<%=author%>/<%= mashup
%>/" target="_blank">HTML Interface</a> to the service'
}
- isCustomUiAvailable('services/<%=author%>/<%= mashup %>',
customUiCallback);
+ isCustomUiAvailable('<%=httpUrl%>services/<%=author%>/<%=
mashup %>', customUiCallback);
</script>
- <li><a href="services/<%=author%>/<%= mashup %>?tryit"
title="?tryit"
+ <li><a href="<%=httpUrl%>services/<%=author%>/<%= mashup
%>?tryit" title="?tryit"
target="_blank">Try</a> the
service
</li>
- <li>Read <a href="services/<%=author%>/<%= mashup %>?doc"
title="?doc"
+ <li>Read <a href="<%=httpUrl%>services/<%=author%>/<%= mashup
%>?doc" title="?doc"
target="_blank">API
documentation</a>
</li>
<li>View the <a
- href="services/<%=author%>/<%= mashup
%>?source&content-type=text/plain"
+ href="<%=httpUrl%>services/<%=author%>/<%= mashup
%>?source&content-type=text/plain"
title="?source" target="_blank">source code</a></li>
</ul>
@@ -443,25 +450,25 @@
<td>
<div class="mashup_details">
<ul>
- <li><a href="services/<%=author%>/<%= mashup
%>?wsdl2&annotation=true">WSDL 2.0</a>
+ <li><a href="<%=httpUrl%>services/<%=author%>/<%= mashup
%>?wsdl2&annotation=true">WSDL 2.0</a>
(<a
- href="services/<%=author%>/<%= mashup
%>?wsdl2">raw</a>)
+ href="<%=httpUrl%>services/<%=author%>/<%= mashup
%>?wsdl2">raw</a>)
</li>
- <li><a href="services/<%=author%>/<%= mashup
%>?wsdl&annotation=true">WSDL 1.1</a>
+ <li><a href="<%=httpUrl%>services/<%=author%>/<%= mashup
%>?wsdl&annotation=true">WSDL 1.1</a>
(<a
- href="services/<%=author%>/<%= mashup %>?wsdl">raw</a>)
+ href="<%=httpUrl%>services/<%=author%>/<%= mashup
%>?wsdl">raw</a>)
</li>
- <li><a href="services/<%=author%>/<%= mashup
%>?xsd&annotation=true">XML Schema</a>
+ <li><a href="<%=httpUrl%>services/<%=author%>/<%= mashup
%>?xsd&annotation=true">XML Schema</a>
(<a
- href="services/<%=author%>/<%= mashup %>?xsd">raw</a>)
+ href="<%=httpUrl%>services/<%=author%>/<%= mashup
%>?xsd">raw</a>)
</li>
- <li><a href="services/<%=author%>/<%= mashup
%>?stub&content-type=text/plain">Javascript
+ <li><a href="<%=httpUrl%>services/<%=author%>/<%= mashup
%>?stub&content-type=text/plain">Javascript
(DOM) stub</a> - optimum for a cross-browser web page
</li>
- <li><a href="services/<%=author%>/<%= mashup
%>?stub&lang=e4x&content-type=text/plain">Javascript
+ <li><a href="<%=httpUrl%>services/<%=author%>/<%= mashup
%>?stub&lang=e4x&content-type=text/plain">Javascript
(E4X) stub</a> - optimum for a Firefox web page or Mashup
with a fixed IP address
</li>
- <li><a href="services/<%=author%>/<%= mashup
%>?stub&lang=e4x&localhost=true&content-type=text/plain">Javascript
+ <li><a href="<%=httpUrl%>services/<%=author%>/<%= mashup
%>?stub&lang=e4x&localhost=true&content-type=text/plain">Javascript
(E4X) stub using "localhost" endpoints</a> - optimum for a
Mashup hosted on this server
</li>
</ul>
_______________________________________________
Mashup-dev mailing list
[email protected]
http://www.wso2.org/cgi-bin/mailman/listinfo/mashup-dev