users@woodstock.java.net

Rendering fails on all browsers

From: Federico Vela <fvela_at_paysett.com>
Date: Tue, 10 Jun 2008 14:53:08 -0500

Hi list,

I have a small web app that has had problems rendering on some pc's
running firefox.

Now i'm trying to redeploy the latest, except the controls do not render
on any platform now!!!

Object cannot be created in this context" code: "9
(no name)() Blogger (line 89)
loaded()bootstrap.js (line 1002)
_callLoaded()bootstrap.js (line 1087)
_modulesLoaded()bootstrap.js (line 1074)
_loadInit(load )



woodstock4_3._base.body is not a constructor
woodstock4_3._dojo.addOnLoad(function() {new
woodstock4_3._base.body('/index.xhtml',
'/Blogger/index.xhtml',null,null,'com_sun_webui_util_FocusManager_focusElementId',true);});90



I have upgraded to latest woodstock and here's the page:

<f:view xmlns="http://www.w3.org/1999/xhtml"
        xmlns:w="http://www.sun.com/webui/webuijsf"
        xmlns:f="http://java.sun.com/jsf/core"
        xmlns:webuijsf="http://www.sun.com/webui/webuijsf">
    <w:page frame="false"
            xhtml="false">
            <w:html>
                <w:head title="PaySett Blogger"/>
                <w:body>
                    <w:messageGroup />
                    <w:markup tag="h1">PaySett Blogger</w:markup><br/>
                    <w:markup tag="div"
styleClass="#{themeStyles.CONTENT_MARGIN}">
                        <w:form id ="loginForm">
                            Username123 : <w:textField id="tfUsername"
text="#{LoginBean.username}" /><br/>
                            Password : <w:passwordField id="tfPassword"
text="#{LoginBean.password}" /><br/>
                            <w:button id="cmbSubmit"
                                      action="#{LoginBean.doLogin}"
                                      primary="true"
                                      text="Login"/>
                            <w:hiddenField id="isLoggedIn"
value="#{LoginBean.isLoggedIn}"/>
                        </w:form>
                    </w:markup>
                </w:body>
            </w:html>
    </w:page>
</f:view>

Any ideas would be highly appreciated!


Federico Vela



Dan Labrecque wrote:
> Actually, I meant to use a "return" statement like so:
>
> function init() {
> var domNode = document.getElementById("form1:dropDown1");
> if (domNode == null || typeof domNode.subscribe !=
> "function") {
> return setTimeout('init();', 10);
> }
> domNode.subscribe(domNode.event.refresh.endTopic,
> processEvents, "update");
> }
>
> If your alerts are not being executed, it may be that you have the
> wrong id.
>
> Dan
>
> Ryan de Laplante wrote:
>> The init function was causing hundreds of "dojo.event has no
>> properties" errors. I think you intended for the subscribe to be in
>> an else block, so I changed it to look like this:
>>
>> function init() {
>> var domNode = document.getElementById('form1:dropDown1');
>> if (domNode == null || domNode.event == null) {
>> setTimeout("init();", 10);
>> } else {
>> alert('before subscribe');
>> domNode.subscribe(domNode.event.refresh.endTopic,
>> processEvents, "update");
>> alert('after subscribe');
>> }
>> }
>>
>> I never see the alerts because it seems that domNode.event always ==
>> null.
>>
>> Thanks,
>> Ryan
>>
>>
>> Dan Labrecque wrote:
>>> When are you calling the document.getElementById function? I suspect
>>> you're calling this too early and the widget has not been created,
>>> yet. In Woodstock 4.3 (next milestone), I've added an onLoad
>>> attribute to the head tag. This will ensure your function is
>>> executed after all widgets have been initialized. In the mean time,
>>> you can use the approach below.
>>>
>>> <head>
>>> <script type="text/javascript">
>>> var processEvents = {
>>> update: function(props) {
>>>
>>> document.getElementById('form1:progressBar1').setProps({"visible":false});
>>>
>>> }
>>> }
>>> function init() {
>>> var domNode = document.getElementById("form1:dropDown1");
>>> if (domNode == null || domNode.event == null) {
>>> setTimeout("init();", 10);
>>> }
>>> domNode.subscribe(domNode.event.refresh.endTopic,
>>> processEvents, "update");
>>> }
>>> </script>
>>> </head>
>>> <body onload="init();">
>>> ...
>>>
>>> Dan
>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe_at_woodstock.dev.java.net
>> For additional commands, e-mail: users-help_at_woodstock.dev.java.net
>>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe_at_woodstock.dev.java.net
> For additional commands, e-mail: users-help_at_woodstock.dev.java.net
>
>
>