Wiki source code of ERPrototaculous
Version 260.1 by Ravi Mendis on 2009/07/16 09:10
Hide last authors
author | version | line-number | content |
---|---|---|---|
![]() |
100.1 | 1 | == Introduction == |
2 | |||
![]() |
209.1 | 3 | ERPrototaculous was developed to provide the ajax functionality in ERDivaLook. |
4 | |||
5 | === What is ERPrototaculous? === | ||
6 | |||
![]() |
233.1 | 7 | Features include: |
![]() |
209.1 | 8 | |
![]() |
233.1 | 9 | * 'Organic' support for Prototype and Scriptaculous in WebObjects. |
![]() |
245.1 | 10 | * No custom Prototype extensions |
11 | * A set of widgets in the Prototype + Scriptaculous family. | ||
![]() |
241.1 | 12 | * Use of [[Unobtrusive Javascript>>http://en.wikipedia.org/wiki/Unobtrusive_JavaScript]]. |
![]() |
249.1 | 13 | * Virtually stateless ajax responses |
![]() |
233.1 | 14 | |
15 | ==== Unobtrusive Javascript in ERPrototaculous ==== | ||
16 | |||
17 | Unobtrusive javascript is used in contrast to on-demand style of ajax programming. | ||
18 | By including Javascript as well as CSS globally in the page wrapper, CSS and/or Javascript doesn't have to load inside ajax requests. | ||
19 | |||
20 | The result is **faster** and more **reliable** ajax in WebObjects applications. | ||
21 | |||
![]() |
259.1 | 22 | ==== Prototype WebObjects Elements ==== |
![]() |
253.1 | 23 | |
![]() |
259.1 | 24 | ##Ajax.Updater## and ##Ajax.Request## have been implemented as WebObjects dynamic elements. |
25 | |||
![]() |
253.1 | 26 | ===== Ajax.Updater ===== |
27 | |||
28 | Support for Prototype's [[Ajax.Updater>>http://www.prototypejs.org/api/ajax/updater]] is in the form of three components: | ||
29 | |||
![]() |
257.1 | 30 | 1. AjaxUpdaterLink |
31 | 1. AjaxUpdaterButton | ||
32 | 1. AjaxUpdaterForm (with ##onsubmit## for ajax form submission) | ||
![]() |
253.1 | 33 | |
![]() |
229.1 | 34 | ==== Prototype + Scriptaculous Widgets ==== |
![]() |
211.1 | 35 | |
![]() |
209.1 | 36 | * Accordion |
37 | * LightWindow | ||
38 | * ModalBox | ||
39 | * CalendarDateSelect | ||
40 | * FileUpload | ||
![]() |
233.1 | 41 | |
42 | == Forms in ERPrototaculous == | ||
43 | |||
44 | Differences from using forms in WebObjects. i.e ##WOForm##: | ||
45 | |||
![]() |
257.1 | 46 | * All form controls must be named. This includes text fields, selects and buttons. |
![]() |
233.1 | 47 | (WebObjects dynamically assigned names are not compatible with ERPrototaculous). |
![]() |
257.1 | 48 | * All forms in an ERPrototaculous app are instances of ##AjaxUpdaterForm##. |
49 | * Form submits can be the form of a: | ||
![]() |
233.1 | 50 | ** Static ##<button>## |
51 | ** WOSubmitButton (if the result is to update whole page/app. | ||
52 | ** AjaxUpdaterButton (to update a **container**). Or | ||
53 | ** AjaxRequestButton (for a background ajax request) |