Java Mailing List Archive

http://www.gg3721.com/

Home » Struts Users Mailing List »

DOJO Dialog Problem? Please help me

prashanth2

2008-08-12

Replies: Find Java Web Hosting

Author LoginPost Reply

Hi,
I am using s2 2.0.11 version, I am able to display the dojo dialog, but the
contents that supposed to appear on the dialog are appearing on the jsp that
iam calling from. I tried many possible ways but endup writing this question
here.
Well I have one more question, instead of displaying a div tag in the dojo
dialog, is there a way to call the server and pass some variables, and based
on the variables i would like to display some content on the dialog in a new
jsp.
Please find the attached output, you can find "name-text box", that actually
should appear on the Dialog.And also please help me in passing some
variables to the dialog, so that i can display a new jsp based on the server
response. http://www.nabble.com/file/p18951580/Doj-Dialog.JPG Doj-Dialog.JPG
Here is my jsp as follows:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<%@(protected)"%>
<html>
<head>
<title>Dojo: Hello World!</title>
<script type="text/javascript" src="<s:url
value='/js/thickBox/jquery.js'/>"></script>
<script type="text/javascript" src="<s:url
value='/js/thickBox/thickbox-compressed.js'/>"></script>

<link href="<s:url value='/theme/main.css'/>" rel="stylesheet"
type="text/css"/>
<link rel="stylesheet" href="<s:url value='/theme/thickbox.css'/>"
type="text/css" media="screen" />
<link
 href="<s:url value='/js/dojo-1.1.1/dijit/themes/tundra/tundra.css'/>"
 rel="stylesheet" type="text/css" />
<link href="<s:url value='/js/dojo-1.1.1/dojo/resources/dojo.css'/>"
 rel="stylesheet" type="text/css" />
<!-- SECTION 1 -->

<script type="text/javascript" src="js/dojo-1.1.1/dojo/dojo.js"
 djConfig="parseOnLoad: true"></script>
<script type="text/javascript">
    // Load Dojo's code relating to the Button widget
    dojo.require("dojo.parser");
    dojo.require("dijit.form.Button");
    dojo.require("dijit.Dialog");
    dojo.require("dijit.form.TextBox");
  </script>

</head>
<body class="tundra">
<s:form action="detailedInfo" method="post">
 <s:actionerror/>
 <s:fielderror/>
 <button dojoType="dijit.form.Button"
onclick="dijit.byId('dialog1').show()">Show Dialog</button>

 <div dojoType="dijit.Dialog" id="dialog1" title="First Dialog"
    onfocus="console.log('user focus handler')"
    onblur="console.log('user blur handler')"
    execute="alert('submitted w/args:\n' + dojo.toJson(arguments[0],
true));">
   <table>
     <tr>
       <td><label for="name">Name: </label></td>
       <td><input dojoType=dijit.form.TextBox type="text" name="name"
id="name"></td>
     </tr>
   </table>
 </div>


</s:form>
</body>
</html>
--
Sent from the Struts - User mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@(protected)
For additional commands, e-mail: user-help@(protected)

©2008 gg3721.com - Jax Systems, LLC, U.S.A.