Open the user's mail after logging in to Domino on the Web

zhaozj2021-02-11  159

/ ** *

Title: mailredirectservlet *

description: After logging in to the Domino server, open the user's email! *

Prerequisites Domino configured to support serverT, *

Open Names.nsf, configuration, server document, Internet protocol, Domino Web engine, Java server applet, select: Domino server small Program Manager *

After saving, restart Domino *

put this compiled .class file into% Domnio% / data / Domino / servlet directory * < P> Accessible by http: //% server% / servlet / mailredirectservlet: Copyright (C) 2001 - 2004 *

Company: Beyond Daybreak Office *

homepage: http://202.101.111.1/123 *

e-mail: yulimin@163.net * @Author Yulimin * @version 1.0 * /

// package net.echochina.oA.OA.OA;

import java.io.IOException; import javax.servlet.ServletException; import javax.servlet.ServletOutputStream; import javax.servlet.http.HttpServlet; import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpServletResponse;

Import lotus.domino.document; import lotus.domino.notsexception; import lotus.domino.notesfactory; import lotus.domino.Domino; import lotus.domino.ction; import lotus.domino.domino.session

Public class mailredirectServlet Extends httpservlet {final static string db_names = "names.nsf";

Public mailredirectServlet () {}

Public void init () throws servletexception {}

Public void destroy () {}

Public void doget (httpservletRequest request, httpservletResponse response) throws servletexception, oException {dopost (request, response);}

public void doPost (HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {String strFullName = request.getRemoteUser (); String strMailFile = ""; response.setContentType ( "text / html; charset = gb2312"); ServletOutputStream out = response. GetOutputStream (); out.println ("Directly open the mail start!

"); Out.println ("Login User Name:" StrfullName "

");

IF (strfullname == null || strfullname.equalsignorecase ("anonymous")) {out.println ("No logged in to Domino server!

"); out.println ("