Log.log(Log.LEVEL_TRACE, MODULE, "Applet parameters: "); Log.log(Log.LEVEL_TRACE, MODULE, "gr_url: " + url); Log.log(Log.LEVEL_TRACE, MODULE, "gr_cookie_name: " + cookieName); Log.log(Log.LEVEL_TRACE, MODULE, "gr_cookie_domain: " + cookieDomain); Log.log(Log.LEVEL_TRACE, MODULE, "gr_cookie_path: " + cookiePath); Log.log(Log.LEVEL_TRACE, MODULE, "gr_album: " + info.albumName);
Log.log(Log.LEVEL_INFO, MODULE, "Applet parameters:"); Log.log(Log.LEVEL_INFO, MODULE, "gr_url:" + url); Log.log(Log.LEVEL_INFO, MODULE, "gr_url_full:" + urlFull); Log.log(Log.LEVEL_INFO, MODULE, "gr_cookie_name:" + cookieName); Log.log(Log.LEVEL_INFO, MODULE, "gr_cookie_domain:" + cookieDomain); Log.log(Log.LEVEL_INFO, MODULE, "gr_cookie_path:" + cookiePath); Log.log(Log.LEVEL_INFO, MODULE, "gr_album:" + info.albumName);
	protected AppletInfo getGRAppletInfo() {		AppletInfo info = new AppletInfo();		info.gallery = new Gallery(GalleryRemote._().getCore().getMainStatusUpdate());		String url = getParameter("gr_url");		String cookieName = getParameter("gr_cookie_name");		String cookieValue = getParameter("gr_cookie_value");		String cookieDomain = getParameter("gr_cookie_domain");		String cookiePath = getParameter("gr_cookie_path");		info.albumName = getParameter("gr_album");		Log.log(Log.LEVEL_TRACE, MODULE, "Applet parameters: ");		Log.log(Log.LEVEL_TRACE, MODULE, "gr_url: " + url);		Log.log(Log.LEVEL_TRACE, MODULE, "gr_cookie_name: " + cookieName);		Log.log(Log.LEVEL_TRACE, MODULE, "gr_cookie_domain: " + cookieDomain);		Log.log(Log.LEVEL_TRACE, MODULE, "gr_cookie_path: " + cookiePath);		Log.log(Log.LEVEL_TRACE, MODULE, "gr_album: " + info.albumName);		if (cookieDomain == null || cookieDomain.length() < 1) {			try {				cookieDomain = new URL(url).getHost();			} catch (MalformedURLException e) {				//Log.logException(Log.LEVEL_ERROR, MODULE, e);				URL documentBase = getDocumentBase();				cookieDomain = documentBase.getHost();				Log.log(Log.LEVEL_INFO, MODULE, "URL probably doesn't have a host part because the Gallery " +						"is in (unsupported) relative mode. Using the Applet documentBase: " + cookieDomain);				try {					url = new URL(documentBase.getProtocol(), documentBase.getHost(), documentBase.getPort(),							url).toString();				} catch (MalformedURLException e1) {					Log.logException(Log.LEVEL_ERROR, MODULE, e1);				}			}		}		info.gallery.setType(Gallery.TYPE_STANDALONE);		info.gallery.setStUrlString(url);		info.gallery.cookieLogin = true;		CookieModule.addCookie(new Cookie(cookieName, cookieValue, cookieDomain, cookiePath, null, false));		return info;	}