I have follwed the three steps to implement the openlog logger in an NSF:
1)
Add the src/com.paulwithers.openLog package to the WebContent/WEB-INF folder.
- Here I copied the files from the openlogjava.nsf into the WebContent/WEB-INF folder
2) Add the XML for the Phase Listener and Managed Bean to your database's facesconfig.xml, also in the WebContent/WEB-INF folder. Ensure it is outside the
AUTOGEN section. Anything within that section gets removed when the NSF is
built.
- Done this
3)
Ensure the WebContent/src folder is added as a source folder, by right-clicking and
selecting Build Path > Use as source folder.
- Done this
Then I copied the ccLayout… xsp and the ErrorOnClick.xsp to my db and clicked the button. Then the following error appears:
Unexpected runtime error
The runtime has encountered an unexpected error.
Error source
Page Name:/ErrorOnClick.xsp
Control Id: button1
Property: onclick
Exception
Error while executing JavaScript action expression
Script interpreter error, line=1, col=84: [ReferenceError] 'com' not found
JavaScript code
1: com.paulwithers.openLog.OpenLogItem.logEvent(null,com.paulwithers.util.OpenLogItem.getXspProperty(“xsp.openlog.filepath”,““),null,null);