Data Binding : Current Record Binding

Description:Current record binding is a key feature of the data binding functionality included in Dynamic HTML. Current record binding allows a page author to merge data with HTML elements on the client. The data is supplied by a data source object included in the page. Individual HTML elements reference the data source object using the DATASRC and DATAFLD attributes. DATASRC is set to "#" plus the ID of the data source object. DATAFLD is set to the name of the column that holds the data. (DATASRC and DATAFLD are W3C-proposed extensions to HTML.)

More Details
The feature is named "current record binding" because data from the columns of the current record of the data source is displayed in the bound elements. When the page author, through script or another element on the page, changes the position of the current record, the data from the new current record is displayed in the elements. Although this feature is like the data binding supported in Microsoft Visual Basic, it does not require controls-you can bind directly to HTML elements.
The key advantage to current record binding is that the data display takes place on the client. A round trip to the server is not necessary to obtain the next record of the data set-you don't have to maintain the client state on the server or hidden in the client page, and you don't have to write a CGI script. With the enhanced user experience and increased speed of browsing, it's easy to see the direct benefits of current record binding.

Browser/Platform Compatibility
Today only Microsoft Internet Explorer 4 and greater supports data binding. It is possible for other browsers to use server-side scripting to provide similar functionality; however, you must keep track of the client state and construct the pages on the server to send to the client.
Sites that already support server-side data access might include a single page that can take advantage of the data binding features of Internet Explorer 4 and greater and also support down-level browsers. In general, this takes about 10 percent more effort than building the page to support server-side data access alone. This extra effort is quickly repaid by a decrease in server hits and increased usability benefits to users of Internet Explorer 4 and greater.

Usage
The current record binding feature can be used to construct data input forms and show detailed information on a record-by-record basis.

Complete Article

Hide comments

Comments

  • Allowed HTML tags: <em> <strong> <blockquote> <br> <p>

Plain text

  • No HTML tags allowed.
  • Web page addresses and e-mail addresses turn into links automatically.
  • Lines and paragraphs break automatically.
Publish