OpenNTF.org - XPages Wiki
XPages WikiOpenDocument[/Projects/pmt.nsf/ProjectView?ReadForm&Query=XPages%20Wiki~Bugs]

My Links (Not logged in)
User Name Password
Hosted by Prominic.NET

   Project: XPages Wiki (Managed by Steve Castledine, Niklas Heidloff)
Actions:

Hide details for The bugThe bug
Bug ID: NOSS-7VNSSN
Description
Submitted by:Stepan Karandin
Project Master Chef:Steve Castledine
Niklas Heidloff
Bug type:Functionality
Brief Description:Broken URL under Edit button
Severity:High
Version0.04
Status:

Details
Environment:
1. Domino 8.5 Win32 running http task at 192.168.х.х:yyy
2. Router between 192.168.x.x and WWW
3. Port mapping from Router:80 to 192.168.х.х:yyy

Expected:
1. Open http://192.168.х.х:yyy/wiki.nsf/dx/CompanyMedia from LAN
2. Click Edit
3. URL http://192.168.х.х:yyy/wiki.nsf/editpage.xsp?documentId=EB1D36561FD43CE5C325762A00480C23&action=editDocument opens
4. Open http://Router/wiki.nsf/dx/CompanyMedia from WWW
5. Click Edit
6. URL http://Router/wiki.nsf/editpage.xsp?documentId=EB1D36561FD43CE5C325762A00480C23&action=editDocument opens

In fact:
6. URL http://192.168.х.х:yyy/wiki.nsf/editpage.xsp?documentId=EB1D36561FD43CE5C325762A00480C23&action=editDocument opens

Solution:
Under the Edit hotspot in the prtContent.xsp replace for both threads

var url=@LeftBack(database.getUrl(),"/")+facesContext.getExternalContext().getRequestContextPath();
var id=document1.getDocument().getUniversalID();

facesContext.getExternalContext().redirect(url+"/editpage.xsp?documentId="+id+"&action=editDocument");

by

var url:XSPUrl;
//return "View By Category";
try {
var url=@LeftBack(context.getUrl().toString(),"/")+facesContext.getExternalContext().getRequestContextPath();
var id=document1.getDocument().getUniversalID();
facesContext.getExternalContext().redirect(url+"/editpage.xsp?documentId="+id+"&action=editDocument");
} catch(e) {
return "";
}


Action taken
Status:Investigating
Implemented in Release:
Fix Details:Unfortunately I cannot contain testing for configurations like this and this code breaks the edit button for most other users so needs further investigation

Modification history
Entered 07-Sep-2009 16:08 by Stepan Karandin. Last Modified 23-Dec-2009 10:33 by Steve Castledine.