Problem with button not firing...

I’m having a very strange problem -It may be a configuration issue with Apache or Tomcat rather than Vaadin, but I don’t see how and I don’t know where to start looking…

I have written a web app using Vaadin and installed the war file on a server in a Tomcat container that is front-ended by an Apache web server. And it works just fine.

Now I have installed a new server and installed Apache and Tomcat on it and dropped the war file into the Tomcat directory. When I point my browser (Chrome, Firefox, Safari) at the new system, it brings up my login screen and lets me enter a username and password. And then - nothing… Firebug doesn’t show a message being sent to the server, there are no errors in the httpd log files or the tomcat log file - just nothing. The login button blinks the tab on my browser but it doesn’t seem to call the onLogin() function.
This is the same war file - byte for byte identical - that runs fine on my original testbed. So what would cause this?

Here is a stripped down version of the login page - I won’t guarantee it will compile as shown, but I have not touched any of the html code or the beginning of the onLogin() function.

Note that when the login screen is displayed, the message ‘Start Login Screen…’ shows up in my log file. But the message ‘User: username’ never prints…

One other thing to note - the login screen has a second button called ‘Report Problem’ (not shown in the code snippet below). If I click that button, it brings up
a different page in the application, so the basic button functionality is still working…

Any help you can give me would be appreciated… Thanks in advance,


public class LoginScreen extends VRSN_LoginScreen {
	private static final long serialVersionUID = 1L;
	private static final VRSNLogger Logger = VRSNLogger.getLogger(LoginScreen.class);

	public LoginScreen(JART_Application app){
		super(app);"Start Login Screen...");

		// The application caption is shown in the caption bar of the
		// browser window. We set it here and not in the application
		// init() to make switching language easier.


		addComponent(new VRSN_PageHeader(getApp().getAppTitle()));

		Panel loginPanel = new Panel("Enter Userid/Password to log in");

		LoginForm loginForm = new LoginForm() {
			private static final long serialVersionUID = -1175293455878477596L;

			protected byte[] getLoginHTML() {

				String appUri = getApplication().getURL().toString()
						+ getWindow().getName() + "/";

				return ("<!DOCTYPE html PUBLIC \"-//W3C//DTD "
						+ "XHTML 1.0 Transitional//EN\" "
						+ "\""
						+ "DTD/xhtml1-transitional.dtd\">\n" + "<html>"
						+ "<head><script type='text/javascript'>"
						+ "var setTarget = function() {" + "var uri = '"
						+ appUri
						+ "loginHandler"
						+ "'; var f = document.getElementById('loginf');"
						+ "document.forms[0]
.action = uri;document.forms[0]
						+ ""
						+ "var styles = window.parent.document.styleSheets;"
						+ "for(var j = 0; j < styles.length; j++) {\n"
						+ "if(styles[j]
.href) {"
						+ "var stylesheet = document.createElement('link');\n"
						+ "stylesheet.setAttribute('rel', 'stylesheet');\n"
						+ "stylesheet.setAttribute('type', 'text/css');\n"
						+ "stylesheet.setAttribute('href', styles[j]
						+ "document.getElementsByTagName('head')[0]
						+ "}"
						+ "}\n"
						+ "function submitOnEnter(e) { var keycode = e.keyCode || e.which;"
						+ " if (keycode == 13) {document.forms[0]
.submit();}  } \n"
						+ "</script>"
						+ "</head><body onload='setTarget();' style='margin:0;padding:0; background:transparent;' class=\""
						+ ApplicationConnection.GENERATED_BODY_CLASSNAME
						+ "\">"
						+ "<div class='v-app v-app-loginpage' style=\"background:transparent;\">"
						+ "<iframe name='logintarget' style='width:0;height:0;"
						+ "border:0;margin:0;padding:0;'></iframe>"
						+ "<form id='loginf' target='logintarget' onkeypress=\"submitOnEnter(event)\" method=\"post\">"
						+ "<table>"
						+ "<tr><td>" + "Username: " + "</td>"
						+ "<td><input class='v-textfield' style='display:block;' type='text' name='username'></td></tr>"
						+ "<tr><td>" + "Password: " + "</td>"
						+ "<td><input class='v-textfield' style='display:block;' type='password' name='password'></td></tr>"
						+ "</table>"
						+ "<div><div onclick=\"document.forms[0]
.submit();\" tabindex=\"0\" class=\"v-button\" role=\"button\" ><span class=\"v-button-wrap\"><span class=\"v-button-caption\">" + "Login" + "</span></span></div></div></form></div>" + "</body></html>")

		loginForm.addListener(new LoginListener() {
			private static final long serialVersionUID = -4471412876480488624L;

			public void onLogin(LoginEvent event) {
				dbManager_JART dbMgr = null;
				String username = event.getLoginParameter("username");
				String password = event.getLoginParameter("password");
				User u = null;
				boolean b = false;
				int idx = 0;"User: " + username);

				dbMgr = getApp().getDbMgr();

				u = dbMgr.validateUser(username, password);
                 ... lots more code here....


		setComponentAlignment(loginPanel, Alignment.MIDDLE_CENTER);

		HorizontalLayout footer = new HorizontalLayout();

One followup - using Firebug, under the ‘Net’ category I see the following message:

URL Status Domain
Post LoginHandler Aborted

So the button is actually firing - but what would cause it to abort and where should I be looking? Again, I’m guessing this is probably
a configuration issue with Apache or Tomcat more than Vaadin… but I could use some help - that isn’t my area of expertise.



No idea really what it could be - haven’t come across something like this before. Nothing in tomcat/apache logs?

Nothing at all in the tomcat or the Apache logs. But it appears that the problem was that my self-signed certificate had the host name and I was typing the IP address
into the browser and that caused system to abort my request - but without any indication of where the problem actually was. By putting the host name into
the web browser (and also putting the FQDN into /etc/hosts) I was able to get the browser to connect to my program.

Not a Vaadin problem (thank goodness :)) and problem solved…