Page Fragment and javascript - need help please

Hi all..
I have a page fragment (being used as a header) and am trying to get a text field in this page fragment to recieve a value from a javascript (that is embeded in the page fragment).. see the example below..
--------------PageFragment1----------------------------------
<?xml version="1.0" encoding="UTF-8"?>
<div style="-rave-layout: grid; width: 400px; height: 200px" xmlns:f="http://java.sun.com/jsf/core" xmlns:ui="http://www.sun.com/web/ui">
<f:subview id="Fragment1">
<ui:textField binding="#{Fragment1.textField1}" id="textField1" style="position: absolute; left: 180px; top: 30px; width: 165px; height: 15px">
<SCRIPT>
var d = new Date();
document.getElementById("Fragment1:textField1").value = d.toLocaleString();
</SCRIPT>
</ui:textField>
</f:subview>
</div>
My problem is that doesn't matter what I do I cannot set the textField1 value from the script. For the actual application it does need to be a javascript - does anyone know how to do this on a page fragment as opposed to a plain page...
The actual error I get is on the client side and it states that document.getElementById is null... :( someone please help.
Thanks in advance.

You probably need to prepend "form1:" to the id (or whatever your form's id is) One sure fire way to figure this out is choose view source in your browser and search for the target field.

Similar Messages

Maybe you are looking for

  • Acrobat 9.0 Pro Slow Moving Buttons

    Hi All, Im new here but am experiencing considerable delay position buttons.  Basically, its slow to create a button and to actually move the reposition the button. I am running Windows Vista Enterprise 32 bit with: - Acrobat Pro 9.0 - Intel 1.8ghz C

  • Baffled by what I need

    I have to admit, I'm baffled by all this. Nowhere in the explanations of Airport Express or any Airport products for that matter does it actually tell me what these things do or what exactly I need to get them to do it. There's a plain English defici

  • Best monitor for beginning graphic designer?

    I am starting out in graphic design. I have been doing a good amount of design for the web and a bit of print also. My laptop is just not cutting it for screen space and I would like to get a monitor that has decent color clarity, etc so that the col

  • Questionnaire in Decision Point

    Hi, Is it possible to maintain Questionnaire in Decision Point? If so can someone help me in providing the process to maintain the same.

  • Solman RFP

    Hi, i need to know What are all the SOLMAN areas get covered in the below topics. Process Related Documentation Repository Testing Management(Test Scripts, link w/ecatts) Definition of Business Process Hierarchy(Scope) Configuration Management Releas