> Maybe with this : <sx:head theme="ajax"/> instead of <sx:head />
theme is not in the DTD of sx:head

> Check to see if you have scriptaculos.js included as well as you dojo
> scripts...I was getting a problem with firefox in relation to this.
> Andrew
Where do I have to have this scriptaculos.js ? Declared in my JSP ? I 
don't see any file named like this in Dojo plugin.

> are you compiling S2.1 yourself?
Yes, with maven 2 from the SVN source (
http://svn.apache.org/repos/asf/struts/struts2/trunk) of today.

> If you set debug="true"
Nothing more happens :/

My JSP :
<%@ taglib uri="/struts-tags" prefix="s"%>
<%@ taglib uri="/struts-dojo-tags" prefix="sx"%>

<sx:head debug="true"/>

<s:form action="contacts">
<table border="0" width="100%" height="100%">
        <sx:datetimepicker name="dateDeb" label="contacts.dateDeb" />
</table>
</s:form>

The HTML generated :
<script language="JavaScript" type="text/javascript">
    // Dojo configuration
    djConfig = {
        isDebug: true,
        bindEncoding: "UTF-8",
          baseRelativePath: "/crm/struts/dojo/",
          baseScriptUri: "/crm/struts/dojo/",
    };
</script>

  <script language="JavaScript" type="text/javascript"
        src="/crm/struts/dojo/dojo.js"></script>

<script language="JavaScript" type="text/javascript"
        src="/crm/struts/ajax/dojoRequire.js"></script>
<link rel="stylesheet" href="/crm/struts/xhtml/styles.css" 
type="text/css"/>
<script language="JavaScript" src="/crm/struts/utils.js" 
type="text/javascript"></script>
<script language="JavaScript" src="/crm/struts/xhtml/validation.js" 
type="text/javascript"></script>
<script language="JavaScript" src="/crm/struts/css_xhtml/validation.js" 
type="text/javascript"></script>

 
<form id="contacts" name="contacts" onsubmit="return true;" 
action="/crm/contacts.action" method="POST">
<table class="wwFormTable">
<table border="0" width="100%" height="100%">
        <tr>
    <td class="tdLabel"><label for="contacts_dateDeb" class="label">Date 
de début
:&nbsp;</label></td>
    <td
><div
     dojoType="struts:StrutsDatePicker"    id="contacts_dateDeb" 
name="dateDeb"    inputName="dojo.dateDeb"  saveFormat="rfc"></div>
</td>
</tr>

        <tr valign="middle" align="center">
                <td colspan="2">
                        Cette page est en cours de construction.<br/>
                        <img src="img/construction.jpg?onglet=20" 
border="0"/>
                </td>
        </tr>
</table>
</table></form>

One thing : /crm is my app context. But I don't have any folder named 
"struts"  in my webapp. Do I have to add the Dojo templates in my webapp, 
or does Struts find it in the dojo-plugin.jar ? How does he find the 
dojo.js, dojoRequire.js, ... ?


Michaël



"Julien Leonard" <[EMAIL PROTECTED]> 
23/05/2007 15:56
Veuillez répondre à
"Struts Users Mailing List" <user@struts.apache.org>


A
"Struts Users Mailing List" <user@struts.apache.org>
cc

Objet
Re: [S2 v2.1.0] DateTimePicker : Dojo javascript error






Maybe with this : <sx:head theme="ajax"/> instead of <sx:head />

2007/5/23, Andrew Penrose <[EMAIL PROTECTED]>:
>
> Check to see if you have scriptaculos.js included as well as you dojo
> scripts...I was getting a problem with firefox in relation to this.
> Andrew
>
> -----Original Message-----
> From: Musachy Barroso [mailto:[EMAIL PROTECTED]
> Sent: 23 May 2007 14:15
> To: Struts Users Mailing List
> Subject: Re: [S2 v2.1.0] DateTimePicker : Dojo javascript error
>
> I just compiled/deployed the dojo plugin and showcase seems to be 
working
> fine, are you compiling S2.1 yourself?
>
> musachy
>
> On 5/23/07, Musachy Barroso <[EMAIL PROTECTED]> wrote:
> >
> > that usually means that there is a javascript error in one of the 
struts
> > dojo widgets. If you set debug="true" on the head tag you should a lot
> of
> > errors on the page.
> >
> > musachy
> >
> > On 5/23/07, [EMAIL PROTECTED] <[EMAIL PROTECTED] >
> > wrote:
> > >
> > > Hi all,
> > >
> > > I try to insert a datetimepicker tag in my JSP, and I have the
> following
> > >
> > > javascript error  :
> > > symbol 'struts.widget' is not defined after loading '__package__.js'
> > >
> > > here is my JSP :
> > > <%@ taglib uri="/struts-dojo-tags" prefix="sx"%>
> > >
> > > <sx:head />
> > > <s:form action="contacts">
> > >
> > > <table border="0" width="100%" height="100%">
> > >         <tr>
> > >                 <td>
> > >                         <sx:datetimepicker name="dateDeb" label=
> > > "test.datepicker" />
> > >                 </td>
> > >         </tr>
> > > </table>
> > >
> > > </s:form>
> > >
> > > I'm in version 2.1.0-SNAPSHOT (of today) for "core",
> > > "codebehind-plugin",
> > > "dojo-plugin", "sitemesh-plugin", "spring-plugin" and "tiles-plugin"
> > > jars.
> > >
> > > What's wrong ?
> > >
> > > Thanks for your help,
> > >
> > > Regards,
> > >
> > > Michaël
> >
> >
> >
> >
> > --
> > "Hey you! Would you help me to carry the stone?" Pink Floyd
>
>
>
>
> --
> "Hey you! Would you help me to carry the stone?" Pink Floyd
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>

Reply via email to