onsubmit is a javascript method, not a server side method. You just told the form to evaluate your EL and send the result down as javascript
On 5/25/08, Ido Tamir <[EMAIL PROTECTED]> wrote: > > Hi, > even when I have a simple page, containing nothing but a form, > the onsubmit function is called automatically when I load the page, > buy simply opening a browser (firefox) to localhost:8080/test/test.seam > > Is this normal? It happens with trinidad 1.2.8 and 1.2.5. > I have to admit that my config is not that simple because I use SEAM, but > it looks rather standard (taken from the trinidad example in SEAM). > > page: > > <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" > > "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> > <trh:html xmlns="http://www.w3.org/1999/xhtml" > xmlns:ui="http://java.sun.com/jsf/facelets" > xmlns:h="http://java.sun.com/jsf/html" > xmlns:f="http://java.sun.com/jsf/core" > xmlns:tr="http://myfaces.apache.org/trinidad" > xmlns:trh="http://myfaces.apache.org/trinidad/html"> > > <trh:head title="test"> > </trh:head> > <trh:body> > <tr:form onsubmit="#{testDAO.setChange()}"> > </tr:form> > </trh:body> > </trh:html> > > bean: > package org.jockeysoft.better.dao; > > import org.jboss.seam.annotations.Logger; > import org.jboss.seam.annotations.Name; > import org.jboss.seam.log.Log; > > > @Name("testDAO") > public class TestDAO { > @Logger private Log log; > > public void setChange(){ > log.error("called change"); > } > > } > -- > View this message in context: > http://www.nabble.com/-Trinidad--tr%3Aform-onsubmit-called-at-page-load--tp17455941p17455941.html > Sent from the MyFaces - Users mailing list archive at Nabble.com. > >

