cancel
Showing results for 
Search instead for 
Did you mean: 

Replacing irpts while logging out of MII

Former Member
0 Kudos

I need to force a logout using the Relogin.jsp and then try to connect to a particular irpt. When I try to connect to an irpt it should display the login screen. I want to do all of this within the same window. The below function is how I have it set up, but removing the setTimeout command, does not force the logout. It simply bypasses the logout and opens the irpt. I place the setTimeout, but it does not seem to force the new irpt. Can someone assist me with this problem.

BTW, the function is from a button.

I guess it doesn't like the setTimeout method

function btnTest()
{
	var strUrl = "../test.irpt";
	location.replace('/Lighthammer/Relogin.jsp');
	location.replace(strUrl);

	//setTim*eout(loca*tion.replace(strUrl), '1250');

}

The simplest way to explain this is that I have one irpt opened. I need replace it with another irpt while forcing a log out in between irpts.

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Chip,

Try this link - http://help.sap.com/saphelp_xmii115/helpdata/en/Security/Logging_Out_of_Lighthammer_CMS.htm

Also, I think the time for the setTimeout function is in milliseconds (1250 = 1.25 seconds).

Former Member
0 Kudos

This is the javascript line I used. I do not want to pass credentials because I am trying to force someone to log in.

location.replace('/Lighthammer/Relogin.jsp?target=/XYZ/QA/QA_XrayMonitorNEW.irpt');

The above line returns this address in the url and I need to get rid of the suffix in bold below.

htt*p://xmiidev/XYZ/QA/QA_XrayMonitorNEW.irpt &sniffer=Microsoft%20Internet%20Explorer%2C7%2C1028%2C1920%2Cen

When I manually remove it, I get what I need to continue. How can I get rid of the suffix?

Former Member
0 Kudos

I'm not sure why the sniffer string comes back. I am getting the same results. If I remove the sniffer snippet from the url, I am getting a 302 error. A 302 error is a badly formed redirect url (server side error). Might be a bug?

To note though, the Relogin.jsp?target= string needs to be encoded. So "/XYZ/QA/QA_XrayMonitorNEW.irpt" should probably be something like this "%2FXYZ%2FQA%2FQA_XrayMonitorNEW%2Eirpt". Check the help docs for complete encoding characters.

Former Member
0 Kudos

This is what I have now. I am still getting the sniffer in the URL along with a "page can not be found error.

location.replace('/Lighthammer/Relogin.jsp?target=%2FXYZ%2FQA%2FQA%5FXrayMonitorNEW%2Eirpt');

URL causing error...

htt*p://xmiidev/XYZ/QA/QA_XrayMonitorNEW.irpt&sniffer=Microsoft%20Internet%20Explorer%2C7%2C1028%2C1920%2Cen

I remove the sniffer and it takes me to the destination, but it does not ask me to login. The Data grid does not have data so I refresh (up to 3 or 4 times) until it ask me to log in.

If this is a bug that needs to be corrected, I need a solution. Is there anyway else I can work around this?

Answers (0)