Last modified by Denis Frolov on 2012/01/21 22:03

From version 13.1
edited by smmccraw
on 2007/07/08 09:44
Change comment: There is no comment for this version
To version 15.1
edited by Quinton Dolan
on 2007/07/08 22:50
Change comment: There is no comment for this version

Summary

Details

Page properties
Author
... ... @@ -1,1 +1,1 @@
1 -XWiki.smmccraw
1 +XWiki.qdolan
Content
... ... @@ -16,13 +16,14 @@
16 16  
17 17  When you first create a WebObjects project, you will have just one 'Component', the 'Main' one.
18 18  A WebObjects component consists of a folder and a bunch of files, but at this stage we're really only interested in 2:
19 -<ul>
20 -<li>Main.wo - which contains the interface</li>
21 -<li>Main.java - where we'll put the logic for the Main.wo page.</li>
22 -</ul>
19 +
20 +
21 +* Main.wo - which contains the interface
22 +* Main.java - where we'll put the logic for the Main.wo page.
23 +
23 23  Double-click on the 'Main.wo' file to edit the interface in WebObjects Builder.
24 24  
25 -You should see something like the screen above. This is how a WebObjects component looks in WebObjects Builder. The top half of the window is a What-You-See-Is-What-You-Get (most of the time (WYSIWYG(MOTT)) HTML editor where you can design your pages. The bottom half of the window is used to connect interface elements to variables in the 'logic' section of your web application.
26 +You should see something like the screen above. This is how a WebObjects component looks in WebObjects Builder. The top half of the window is a What-You-See-Is-What-You-Get (most of the time (WYSIWYG(MOTT)) HTML editor where you can design your pages. The bottom half of the window is used to connect interface elements to variables in the 'logic' section of your web application.
26 26  Add the text "Hello, what is your name?" by typing in the top half of the window.
27 27  
28 28  Add some form elements to the page by selecting a 'WOForm', a 'Text Field' and a 'Submit Button' from the 'Forms' menu bar item.
... ... @@ -53,22 +53,16 @@
53 53  {{code}}
54 54  
55 55  public class Main extends WOComponent {
56 -{panel}
57 57   public String visitorsName;
58 58   public String message;
59 -{panel}
60 -
61 -{panel}
59 +
62 62   public Main(WOContext context) {
63 63   super(context);
64 64   }
65 -{panel}
66 66  
67 67   public WOComponent sayHello() {
68 -{panel}
69 69   return null;
70 70   }
71 -{panel}
72 72  }
73 73  
74 74  {{/code}}
... ... @@ -92,23 +92,17 @@
92 92  {{code}}
93 93  
94 94  public class Main extends WOComponent {
95 -{panel}
96 96   public String visitorsName;
97 97   public String message;
98 -{panel}
99 99  
100 -{panel}
101 101   public Main(WOContext context) {
102 102   super(context);
103 103   }
104 -{panel}
105 105  
106 106   public WOComponent sayHello() {
107 -{panel}
108 108   message = "Hi there, " + visitorsName + "!";
109 109   return null;
110 110   }
111 -{panel}
112 112  }
113 113  
114 114  {{/code}}