Can�t instantiate... why?

Why can�t I do something like this:
Class: User.java , this is my example model class, used with hibernate
public class User {
  private String login;
  // getters and setters
}Class: LoginBean.java, this is my ManagedBean
public class LoginBean {
  private User user;
  // getters and setters
}JSF: login.jsp , this is the jsp file that uses the UserBean class
<f:view>
  <h:form>
     Login: <h:inputText id="login" value="#{loginBean.user.login}"/>
  </h:form>
</f:view>
...Doing this gives me an
javax.faces.FacesException: Can't instantiate class ....
I think that it might help a lot if we could do something like this....!

Try keeping your managed bean in faces-confix.xml file
<managed-bean>
          <managed-bean-name>loginUser</managed-bean-name>
          <managed-bean-class>com.XXX.XXX.common.domain.LoginUser</managed-bean-class>
          <managed-bean-scope>session</managed-bean-scope>
     </managed-bean>

Similar Messages

  • My IPad cannot download live Tv from skygo. I have no problem with my lap top so I assume the broad band is okay. Can anybody suggest why the live streaming will not work on my iPad one.

    My IPad cannot download live Tv from skygo. I have no problem with my lap top so I assume the broad band is okay. Can anybody suggest why the live streaming will not work on my iPad .

    Are you using the Sky Go app to try and watch it ? If so are you logged in with your Sky account ?
    If you are using the app then you could try closing the app completely and see if it works when you re-open it : from the home screen (i.e. not with Sky Go 'open' on-screen) double-click the home button to bring up the taskbar, then press and hold any of the apps on the taskbar for a couple of seconds or so until they start shaking, then press the '-' in the top left of the Sky Go app to close it, and touch any part of the screen above the taskbar so as to stop the shaking and close the taskbar.
    If that doesn't work then you could try a reset : press and hold both the sleep and home buttons for about 10 to 15 seconds (ignore the red slider), after which the Apple logo should appear - you won't lose any content, it's the iPad equivalent of a reboot.

  • I've seen all the posts for fixing the wifi on the 4s, none of them work!  So, who can tell me why my iPhone 4S cannot find any wifi when it used to easily, and when it does it can never connect?

    I've seen all the posts for fixing the wifi on the 4s, none of them work!  So, who can tell me why my iPhone 4S cannot find any wifi when it used to find wifi, and when it does find a wifi network it can never connect?  You think apple would have a clue how to fix it!  Because turning the wifi on and off doesn't work, resorting network settings doesn't work, even restoring phone to factory default doesn't work...

    Did not work. I've selected iMessage to ON and left it. After a few hours I recieved a message "activation unsuccessful. Turn on iMessage to try again". This has been going on for the past 3 days.

  • My ipod 60gb classic is showing as fully charged until I connect it to my pc when it comes up with the error message, 'please wait very low battery' and the little wheel goes round and nothing happens, can anyone explain why this is and what i can do?

    My ipod 60gb classic is showing as fully charged until I connect it to my pc when it comes up with the error message, 'please wait very low battery' and the little wheel goes round and nothing happens, can anyone explain why this is and what i can do?

    I have worked my way through the assistant and nothing works. I have tried connecting in disc mode but although the screen on the ipod is showing that the device is charged and that it is in disc mode as soon as I connect it to the computer it comes up with the error message 'please wait very low battery' and stays like that until I disconnect when it appears to be OK again. I have tried on both pc and mac.
    BTW the ipod is an ipod video not classic if that makes any difference.
    Thanks

  • After updating software on my Apple TV it is asking to connect to iTunes. Can't understand why?

    After updating software on my Apple TV it is asking to connect to iTunes. Can't understand why?

    You can try borrowing one. These cables are common for Android, Kindle etc. users.
    Here are some steps and notes to try:
    MANY people are reporting they've had to try multiple micro USB cables to find one that works. I got one that worked from a neighbor.
    For clarification, this needs to be a "micro" USB, not a "mini" USB
    Some people have also reported they've had to try the Restore process more than once.
    1. Unplug Apple TV and move it to your computer running latest version of iTunes.
    2. Quit iTunes if running.
    3. Plug micro USB cable to the back of the Apple TV.
    4. Power the Apple TV using  the AC cable.
    5. iTunes shoud either launch itself (a good indication that the micro USB cable you're using is compatible), or launch iTunes.
    6. Click Restore. Software will download and install (big file).

  • Windows 8 can not connect RemoteApp on W2K12 RDS, but Windows 7 can connect. Why?

    Hi!
    Windows 8 can not connect RemoteApp (W2K12 RDS), but Windows 7 can connect. Why?
    External and internal DNS name is different, the public Cert is mapped to RD Web Access and a RD GateWay Role.
    The internal cert (issued by enterprise ca) is mapped to RD Connection Broker roles (SSO and Publishing).
    These certifications also be installed on client computers (Personal and Trusted Root Certification Authorities).
    The internal CA revocation list is publicated to a website and this web site is accessible from internet. Ports (3389,3391,443) forwarded to RDS server.
    On windows 7 everything works fine, but Windows 8 can not connect to Remote Apps. Windows 8 can connect to RDS server via Remote Desktop Connection.
    The error:
    Thank you for your answers.

    Check this thread -> 
    http://social.technet.microsoft.com/Forums/windowsserver/en-US/0c0d7c4a-e422-4a6c-99eb-66df26a1ffc6/rdp8-your-computer-cant-connect-to-the-remote-computer-because-an-error-occurred?forum=winserverTS
    and this
    http://support.microsoft.com/kb/2903333
    HTH,
    JB

  • Can anyone answer why in logic pro X I keep getting a window popping up that says Directory not found, result code= -120, followed by another window saying, Fade update failed, (error -120)?

    Can anyone answer, why in Logic Pro X I keep on getting a window popping up saying, Directory not found, result code = -120. Followed by another window saying, Fade update failed, (error -120)?
    I am running the latest version 10.0.5 through a Macbook Pro that has just been upgraded to 16GB Ram and a 960GB SSD which has made it as fast as ****. I upgraded because I was experiencing problems before and it was suggested that I didn't have enough Ram?
    I am using a Focusrite scarlett 2i4 and an Alesis Q61 midi controller. Weirdly, just trying to put a bass line down on a track using the Alesis, the bass sound goes out of tune with the track during recording only. This is very frustrating! I surely can't be the only one experiencing this?
    Many thanks
    Rob.

    Hi
    Time lost could be a problem, but.....
    Sadly, I don't think that there are any Apple docs relating to networked storgae issues with Logic. Other than a 'school' or 'business' setup, NAS/OD/AD setups are not usual circumstances for audio.
    If the issue is one of data backup & security, it may be enough to automatically backup the students local work folders to the NAS.
    If the issue is one of the Users being able to work from any Mac and pick up their files from the server, you are not likely to resolve this problem, without copying the files to the Local Mac.
    CCT

  • I updated my itunes then i couldn't sync my iphone anymore, it shows me that i didn't connect my iphone to my computer, can i know why i can't sync my iphone??? should i reinstall the older version of itunes???

    i updated my itunes then i couldn't sync my iphone anymore, it shows me that i didn't connect my iphone to my computer, can i know why i can't sync my iphone??? should i reinstall the older version of itunes???

    Hello,
    Only option is upgrading your Mac's OSX, since Apple will not allow iOS to go backwards.
    Snow Leopard/10.6.x Requirements...
    General requirements
       * Mac computer with an Intel processor
        * 1GB of memory (I say 4GB at least, more if you can afford it)
        * 5GB of available disk space (I say 30GB at least)
        * DVD drive for installation
        * Some features require a compatible Internet service provider; fees may apply.
        * Some features require Apple’s MobileMe service; fees and terms apply.
    Which apps work with Mac OS X 10.6?...
    http://snowleopard.wikidot.com/
    Call Apple Sales...in the US: 1-800-MY-APPLE. Or Support... 1-800-275-2273
    Other countries...
    http://support.apple.com/kb/HE57
    It looks like they might still have it...
    http://store.apple.com/us/product/MC573Z/A?fnode=MTY1NDAzOA

  • Can anyone help why I am getting this error.

    I am seeing these errors when I try to test my database. I
    can't understand why. Does anyone have any ideas?
    The exact file with different field names works on a
    different table of the same database.
    Thanks for the help.
    Errors in ActionScript.
    Error: Error #2101: The String passed to
    URLVariables.decode() must be a URL-encoded query string containing
    name/value pairs.
    at Error$/throwError()
    at flash.net::URLVariables/decode()
    at flash.net::URLVariables()
    at flash.net::URLLoader/onComplete()
    AS3 CODE
    // Changed the mouse event.
    submit_btn.addEventListener(MouseEvent.CLICK, sendData);
    function sendData(evt:Event) {
    if (fname_txt.text!="" && lname_txt.text !=""
    && street_txt.text!="" && city_txt.text!=""
    && state_txt.text!="" && zip_txt.text!="") {
    //for those using PHP
    var myData:URLRequest = new URLRequest("
    http://**********************");
    myData.method = URLRequestMethod.POST;
    var variables:URLVariables = new URLVariables();
    variables.firstName = fname_txt.text;
    variables.lastName = lname_txt.text;
    variables.streetAddr = street_txt.text;
    variables.cityName = city_txt.text;
    variables.stateName = state_txt.text;
    variables.zipCode = zip_txt.text;
    myData.data = variables;
    var loader:URLLoader = new URLLoader();
    loader.dataFormat = URLLoaderDataFormat.VARIABLES;
    loader.addEventListener(Event.COMPLETE, dataComplete);
    loader.load(myData);
    } else {
    status_txt.text = "All fields are mandatory";
    function dataComplete(event:Event):void {
    status_txt.text = event.target.data.successMessage;
    //status1_txt.text = event.target.data.secondMessage;
    fname_txt.text = "";
    lname_txt.text= "";
    street_txt.text = "";
    city_txt.text = "";
    state_txt.text = "";
    zip_txt.text = "";
    PHP CODE:
    <?php
    //Capture data from $_POST array
    $fname = $_POST['firstName'];
    $lname = $_POST['lastName'];
    $street = $_POST['streetAddr'];
    $city = $_POST['cityName'];
    $state = $_POST['stateName'];
    $zip = $_POST['zipCode'};
    //Connection to database
    $connect = mysql_connect("localhost", "**********",
    mysql_select_db ("mttolcom_testDB", $connect);
    //Perform the query
    $result = mysql_query("INSERT into address (firstName,
    lastName, streetAddr, cityName, stateName, zipCode) values
    ('$fname','$lname','$street','$city','$state','$zip')");
    if($result) echo "writing=Ok&";
    else echo "writing=Error";
    echo 'var1=yes&successMessage=Response from server. The
    data has made the server!';
    // echo 'var2=yes&secondMessage=Your data has been
    received and processed!';
    ?>
    Thanks for the help.
    Mike

    Dear Jain,
    I used CA Type 10 CA Categories as Stock Split for corporate action as below.
    Configuration
    FWK0 posting
    Error Msg

  • Problem:Can't instantiate class

    I tried for many hours to solve the problem but in vain.
    here is the Exception i got from tomcat:javax.servlet.ServletException: javax.servlet.jsp.JspException: javax.faces.FacesException: javax.faces.FacesException: Can't instantiate class: 'core.walid.NwindManagedBean'.. core.walid.NwindManagedBean
         org.apache.jasper.runtime.PageContextImpl.doHandlePageException(PageContextImpl.java:844)
         org.apache.jasper.runtime.PageContextImpl.handlePageException(PageContextImpl.java:781)
         org.apache.jsp.index_jsp._jspService(index_jsp.java:91)
         org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:97)
         javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
         org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:322)
         org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:291)
         org.apache.jasper.servlet.JspServlet.service(JspServlet.java:241)
         javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
         org.netbeans.modules.web.monitor.server.MonitorFilter.doFilter(MonitorFilter.java:362)
         com.sun.faces.context.ExternalContextImpl.dispatch(ExternalContextImpl.java:322)
         com.sun.faces.application.ViewHandlerImpl.renderView(ViewHandlerImpl.java:130)
         com.sun.faces.lifecycle.RenderResponsePhase.execute(RenderResponsePhase.java:87)
         com.sun.faces.lifecycle.LifecycleImpl.phase(LifecycleImpl.java:200)
         com.sun.faces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:117)
         javax.faces.webapp.FacesServlet.service(FacesServlet.java:198)
         org.netbeans.modules.web.monitor.server.MonitorFilter.doFilter(MonitorFilter.java:362)
    cause m�re
    javax.faces.el.EvaluationException: javax.faces.FacesException: javax.faces.FacesException: Can't instantiate class: 'core.walid.NwindManagedBean'.. core.walid.NwindManagedBean
         com.sun.faces.el.ValueBindingImpl.getValue(ValueBindingImpl.java:206)
         com.sun.faces.el.ValueBindingImpl.getValue(ValueBindingImpl.java:154)
         javax.faces.component.UIData.getValue(UIData.java:527)
         javax.faces.component.UIData.getDataModel(UIData.java:856)
         javax.faces.component.UIData.setRowIndex(UIData.java:379)
         com.sun.faces.renderkit.html_basic.TableRenderer.encodeBegin(TableRenderer.java:65)
         javax.faces.component.UIComponentBase.encodeBegin(UIComponentBase.java:683)
         javax.faces.component.UIData.encodeBegin(UIData.java:681)
         javax.faces.webapp.UIComponentTag.encodeBegin(UIComponentTag.java:591)
         javax.faces.webapp.UIComponentTag.doEndTag(UIComponentTag.java:543)
         com.sun.faces.taglib.html_basic.DataTableTag.doEndTag(DataTableTag.java:491)
         org.apache.jsp.index_jsp._jspx_meth_h_dataTable_0(index_jsp.java:161)
         org.apache.jsp.index_jsp._jspx_meth_c_view_0(index_jsp.java:116)
         org.apache.jsp.index_jsp._jspService(index_jsp.java:80)
         org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:97)
         javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
         org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:322)
         org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:291)
         org.apache.jasper.servlet.JspServlet.service(JspServlet.java:241)
         javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
         org.netbeans.modules.web.monitor.server.MonitorFilter.doFilter(MonitorFilter.java:362)
         com.sun.faces.context.ExternalContextImpl.dispatch(ExternalContextImpl.java:322)
         com.sun.faces.application.ViewHandlerImpl.renderView(ViewHandlerImpl.java:130)
         com.sun.faces.lifecycle.RenderResponsePhase.execute(RenderResponsePhase.java:87)
         com.sun.faces.lifecycle.LifecycleImpl.phase(LifecycleImpl.java:200)
         com.sun.faces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:117)
         javax.faces.webapp.FacesServlet.service(FacesServlet.java:198)
         org.netbeans.modules.web.monitor.server.MonitorFilter.doFilter(MonitorFilter.java:362)here is the bean i don't see any problelme it uses JDBC to access the database/*
    * NwindManagedBean.java
    * Created on 4 mars 2007, 01:02
    package Core.walid;
    import java.sql.*;
    import javax.sql.*;
    import java.util.ArrayList;
    import java.util.Collection;
    import java.io.*;
    import javax.servlet.jsp.jstl.sql.*;
    * @author walid
    public class NwindManagedBean implements Serializable{
        private String tableName="Customers";
        private ResultSet resultSet;
        private Connection connection;
        /** Creates a new instance of NwindManagedBean */
        public NwindManagedBean() {
        public String getTableName(){
        return tableName;
        public void setTableName(String tableName){
        this.tableName=tableName;
        public void open(){
        String driver = "sun.jdbc.odbc.JdbcOdbcDriver";
        String url = "jdbc:odbc:Nwind";
        String username = "";
        String password = "";
        try{
            Class.forName(driver);
            connection =DriverManager.getConnection(url,username,password);}
        catch(Exception e){System.out.println(e);}
        public void search(){
          try{ Statement statement=connection.createStatement();
           String query ="select * from "+tableName;
            resultSet=statement.executeQuery(query);
        catch(Exception cnfe) {};
        public ResultSet getResultSet(){
            open();
            search();
            return resultSet;
        public void showResults(){
            int i=1;
           try{ while(resultSet.next())
            System.out.println(resultSet.getString(i));
            i++;
           catch(Exception e){System.out.println("erreur sql"+e);}
    }i declared the bean in faces-config<faces-config>
        <managed-bean>
            <managed-bean-name>NwindManagedBean</managed-bean-name>
            <managed-bean-class>core.walid.NwindManagedBean</managed-bean-class>
            <managed-bean-scope>request</managed-bean-scope>
        </managed-bean>
    </faces-config>and finally the jsf page to list the database contents<%@ taglib uri="http://java.sun.com/jsf/core" prefix="c" %>
    <%@ taglib uri="http://java.sun.com/jsf/html" prefix="h" %>
    <html>
       <HEAD><TITLE>Northwind Customers</title>
        </HEAD>
        <body>
            <center>
                <table border="5">
                    <tr><th class="Northwind customers"></th></tr>
                </table>
                <p>
                <c:view>
                    <h:dataTable value="#{NwindManagedBean.resultSet}"
                    var="dbRow"
                    border="1"
                    >
                    <h:column>
                    <c:facet name="header">
                    <c:verbatim>Company name</c:verbatim>
                    </c:facet>
                    <h:outputText value="#{dbRow.CompanyName}"/>
                    </h:column>
                    <h:column>
                    <c:facet name="header">
                    <c:verbatim>Address</c:verbatim>
                    </c:facet>
                    <h:outputText
                    value="#{dbRow.Address}"/>
                    </h:column>
                    <h:column>
                    <c:facet name="header">
                    <c:verbatim>City</c:verbatim>
                    </c:facet>
                    <h:outputText
                    value="#{dbRow.City}"/>
                    </h:column>
                    </h:dataTable>
                </c:view>
                </center>
        </body>
    </html>

    Hello,
    I'm not sure, but i would try to put the package only in lowercase.
    Your class pakageis declared with first Upper case letter.
    And in you faces-config file, you declared with lower case.
    Note : it's recommanded to use only lower case for package name.
    Regards,
    Sebastien Degardin

  • How can I instantiate and load a new CachedRowSet object from a non-JDBC so

    How can I instantiate and load a new CachedRowSet object from a non-JDBC source?
    cheers

    webrowset reads whole data;
    I would rather need to get data line by line

  • I was wondering if anybody can tell me why the new Apple iPhone 5 is $600 AUD/US more expensive in Australia than the US??? Please explain somebody?

    I was wondering if anybody can tell me why the Apple IPhone 5  is $600 US/AUD more expensive in Australia than in the US!
    thanks

    Thanks for the reply - I still know that this issue is also relevant for so many other apple products which don't involve cellular providers.... I think Australians are tired of paying so much more for things than in the US and other countries.  It used to be explained by the poor Australian dollar but that doesnt exactly work when we are over parity with the US dollar and have been for a while now....

  • RfcAdapter: receiver channel has static errors: can not instantiate RfcPool

    HI,
    While transferring the project from SAP system to PRIMVERA (third party system) system, iam getting the following error:
    com.sap.engine.interfaces.messaging.api.exception.MessagingException: com.sap.aii.adapter.rfc.afcommunication.RfcAFWException: RfcAdapter: receiver channel has static errors: can not instantiate RfcPool caused by: com.sap.aii.adapter.rfc.RfcAdapterException: error initializing RfcClientPool:com.sap.aii.adapter.rfc.core.repository.RfcRepositoryException: can not connect to destination system due to: com.sap.mw.jco.JCO$Exception: (102) RFC_ERROR_COMMUNICATION: Connect to SAP gateway failed Connect_PM TYPE=A ASHOST=192.168.215.138 SYSNR=02 GWHOST=192.168.215.138 GWSERV=sapgw02 PCS=1 LOCATION CPIC (TCP/IP) on local host with Unicode ERROR partner '192.168.215.138apgw02' not reached TIME Sun May 01 06:10:03 2011 RELEASE 710 COMPONENT NI (network interface) VERSION 39 RC -10 MODULE nixxi.cpp LINE 3133 DETAIL NiPConnect2: 192.168.215.138:3302 SYSTEM CALL connect ERRNO 10060 ERRNO TEXT WSAETIMEDOUT: Connection timed out COUNTER
    experts, kindly help me out in resolving this issue.
    Regards,
    Sai

    partner '192.168.215.138apgw02' not reached
    Well if you ask me, theres something seriuosly wrong with above "partner", review the config of the RFC/JCO,
    also you could add more details as above info on its own is not enough to give you and objective answer
    Regards
    Juan

  • Can anybody say why In the layer menu the background color is white when opening a layer mask, and why does it automatically turns black by simply opening the layer mask properties menu? The vector mask is white anyway.

    Can anybody say why In the layer menu, the background color is white when opening a layer mask, and why does it automatically turns black by simply opening the layer mask properties menu? The vector mask is white anyway.

    Topic or subject titles should be clear, pertinent and concise so that individual users can tell at a glance if they can help or not.
    That field is not for attempting to fit your entire question in there.
    Please keep this in mind next time you post.  Thank you.
    A lot more information about your hardware and software is needed.
    BOILERPLATE TEXT:
    If you give complete and detailed information about your setup and the issue at hand,
    such as your platform (Mac or Win),
    exact versions of your OS, of Photoshop (not just "CC", but something like CC2014.v.2.2) and of Bridge,
    your settings in Photoshop > Preference > Performance
    the type of file you were working on,
    machine specs, such as total installed RAM, scratch file HDs, total available HD space, video card specs, including total VRAM installed,
    what troubleshooting steps you have taken so far,
    what error message(s) you receive,
    if having issues opening raw files also the exact camera make and model that generated them,
    if you're having printing issues, indicate the exact make and model of your printer, paper size, image dimensions in pixels (so many pixels wide by so many pixels high). if going through a RIP, specify that too.
    a screen shot of your settings or of the image could be very helpful too,
    etc.,
    someone may be able to help you (not necessarily this poster, who is not a Windows user).
    Please read this FAQ for advice on how to ask your questions correctly for quicker and better answers:
    http://forums.adobe.com/thread/419981?tstart=0
    Thanks!

  • Can anyone explain why all of my Spry Assets on a live website have suddenly stopped working?

    Can anyone explain why all of my Spry Assets on a live website have stopped responding? I have checked that the Spry CSS and JS files are in place. Then checked the files on Dreamweavers live view and they are not working there either. It was fine a few weeks ago, it is almost as if the web browsers have stopped rending Spry, for example, the links for the collapsible panels are not even being recognised as links.
    I am using 'old' spry assets on Dreamweaver CS4 (if that makes a difference). The Spry Assets used are Tabbed Panels and Collapsible Panels.
    Thanks for your help.

    Something has been going on, when I look at the bottom of your document (as pasted below), this is normally all at the top after the links to external style sheets.
    <script src="js/jquery-1.10.2.min.js"></script>
    <script src="js/lightbox-2.6.min.js"></script>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=Edge"/>
       <script type="text/javascript" charset="utf-8" src="Menu_Photography_edgePreload.js"></script>
       <script src="SpryAssets/SpryCollapsiblePanel.js" type="text/javascript"></script>
       <script type="text/javascript">
    <!--
    function MM_swapImgRestore() { //v3.0
      var i,x,a=document.MM_sr; for(i=0;a&&i<a.length&&(x=a[i])&&x.oSrc;i++) x.src=x.oSrc;
    function MM_preloadImages() { //v3.0
      var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array();
      var i,j=d.MM_p.length,a=MM_preloadImages.arguments; for(i=0; i<a.length; i++)
      if (a[i].indexOf("#")!=0){ d.MM_p[j]=new Image; d.MM_p[j++].src=a[i];}}
    function MM_findObj(n, d) { //v4.01
      var p,i,x; if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) {
      d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}
      if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n];
      for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers[i].document);
      if(!x && d.getElementById) x=d.getElementById(n); return x;
    function MM_swapImage() { //v3.0
      var i,j=0,x,a=MM_swapImage.arguments; document.MM_sr=new Array; for(i=0;i<(a.length-2);i+=3)
      if ((x=MM_findObj(a[i]))!=null){document.MM_sr[j++]=x; if(!x.oSrc) x.oSrc=x.src; x.src=a[i+2];}
    //-->
    </script>

Maybe you are looking for