|
|
|
|
|
|
|
|
Using coolets in an enterprise environment (continued)
Generate the form containing hidden fields for the Memo Pad coolet using the MEMO_CUR cursor.
htp.formOpen( curl => 'http://www.coola.com/cgi?bin/addinfo.cgi', cmethod => 'POST',cattributes =>'onsubmit="coolapopup()" TARGET="coolawindow"');
htp.tableOpen( calign => 'CENTER', cattributes => ' border="1" cellspacing="0" cellpadding="0" width="100%"' );
htp.tableRowOpen;
htp.tableData( htf.centerOpen ||
'<B>Special Announcements </B>' ||
htf.centerClose,cattributes =>'width = "100%"');
htp.tableRowClose;
htp.tableRowOpen;
htp.tableData( '<input type= image name = "Coola ?Sync Special Announcements to palm" ALT="Coola ?Sync Special Announcements to palm" src="http://www.coola.com/images/synctopalm.gif" align="bottom" border="0">', cattributes => ' width="100%"', calign => 'CENTER');
htp.tabLERowClose;
htp.tableClose;
for memorec in memo_cur loop
htp.formHidden(cname => 'MEMO', cvalue =>MEMOREC.MEMOCOOLA);
END LOOP;
htp.formClose;
htp.bodyclose;
END;
END coolaweb;
|
An important point to note here is that hidden fields for updating both the Address Book and Memo Pad, as well as .PDB files, can be placed in one HTML form.
The general format for a coolet to be placed in an HTML page itself is listed below. It's extremely important to note that each record has a unique record ID.
The HTML command that displays the button on the HTML page and transfers the information coolet is divided into the following four sections. The sample code pictured in Figure D is provided courtesy of Coola.
FIGURE D
 
The information coolet is divided into four sections. Roll over picture for a larger image.
Section 1
Section 1 loads a small JavaScript that's used to pop up a menu-less, title-less window that notifies the user whether the coolet was loaded properly. The script also closes the window after 10 seconds. This section should appear only once on the page before all the Coola buttons, even if you have multiple buttons on the page.
Section 2
Section 2 begins the FORM tag.
Section 3
Section 3 loads an image from the Coola hub that's displayed as the synchronization button. Partners can cache this button on their Web site for better performance.
Section 4
Section 4 specifies the information to be sent to the Coola hub when a Coola user clicks on the Coola synchronization button. This field has TYPE hidden so it doesn't display on the Web browser. This section is repeated multiple times for multiple coolets.
Test the application We have a number of development devices that are configured with all the identical software that's used in the field. We have successfully synchronized several hundred Address Book entries and attached Address Book notes to these entries. In addition, we have created multi-entry type coolets that simultaneously contain address book entries, memos, documents, and date book entries. This enables one button to add a meeting date, an address contact for the meeting, and a meeting agenda to the Palm handheld all at once.
|
|
|
|
|
|
|
|
|
|
|