admin@glassfish.java.net

Code Review for Issue# 3540

From: Ken Paulsen <Ken.Paulsen_at_Sun.COM>
Date: Mon, 01 Oct 2007 10:36:50 -0700

The following diff fixes issue #3540. Anissa (or anyone else
interested) please review.

Thanks!

Ken


cvs diff -u header.jsf
Index: header.jsf
===================================================================
RCS file: /cvs/glassfish/admin-gui/src/docroot/header.jsf,v
retrieving revision 1.10
diff -u -r1.10 header.jsf
--- header.jsf 5 May 2007 05:26:56 -0000 1.10
+++ header.jsf 1 Oct 2007 17:35:42 -0000
@@ -48,7 +48,20 @@
     />
     <sun:html>
        <sun:head id="propertyhead" >
- "<SCRIPT language="JavaScript"
src="js/adminjsf.js"></script>
+ <sun:script url="/resource/js/adminjsf.js" />
+ // This check is here to ensure the header frame is loaded
in its
+ // own frame. This solves GF issue #3540. This prevents
the login
+ // page from going directly to the header.jsf page when the
session
+ // has expired and someone clicks a link on the header.jsf page.
+ <f:verbatim>
+ <script type="text/javascript">
+ <!--
+ if (window.parent.frames.length == 0) {
+ document.location = "index.jsf";
+ }
+ // -->
+ </script>
+ </f:verbatim>
        </sun:head>
        <sun:body>
            <sun:form id="propertyForm">