Domino中B/S下的附件链接

一、只读链接
thisDb:=@ReplaceSubstring(@ReplaceSubstring(@Subset(@DbName;-1);" ";"+");"\\";"/");
@If(@Attachments!=0;"["+@AttachmentNames+"]";"")

二、可删除链接
thisDb:=@ReplaceSubstring(@ReplaceSubstring(@Subset(@DbName;-1);" ";"+");"\\";"/");
@If(@Attachments!=0;"["+@AttachmentNames+"]";"")


但是,当附件的名称中包含“#”、“&”等特殊符号时(例如jeep#beijing.jpg),上面写的链接在特殊符号处就会被截断,从而导致附件不能正常打开。要解决这个问题,需要在写链接的时候把这些特殊符号进行转换,具体方法如下:
thisDb:=@ReplaceSubstring(@ReplaceSubstring(@Subset(@DbName;-1);" ";"+");"\\";"/");
aa:=@URLEncode("domino";@AttachmentNames);
@If(@Attachments!=0;"["+@AttachmentNames+"]";"")

转载于:https://www.cnblogs.com/hannover/archive/2010/12/03/1895902.html

你可能感兴趣的:(Domino中B/S下的附件链接)